-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathexplanation.html
236 lines (231 loc) · 9.59 KB
/
explanation.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<meta http-equiv="X-UA-Compatible" content="chrome=1" />
<meta name="description" content="APImeal : L'API qui vous simplifie la vie" />
<title>APImeal : L'API qui vous simplifie la vie</title>
<link href="Resources/css/bootstrap.min.css" type="text/css" rel="stylesheet">
<link href="Resources/css/bootstrap-theme.min.css" type="text/css" rel="stylesheet">
<link href="Resources/css/style.css" type="text/css" rel="stylesheet">
<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
try {
var pageTracker = _gat._getTracker("API meal Zia epitech coutur_n seguin_s devaux_a aubine_v lacroi_t pillet_c nantes ");
pageTracker._trackPageview();
} catch(err) {}
</script>
<script src="Resources/js/jquery-1.10.2.min.js"></script>
<script src="Resources/js/bootstrap.min.js"></script>
<script src="Resources/js/script.js"></script>
</head>
<body>
<!-- HEADER -->
<div class="navbar navbar-inverse navbar-fixed-top" role="navigation">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="/">APImeal</a>
</div>
<div class="collapse navbar-collapse">
<ul class="nav navbar-nav">
<li><a href="index.html">Accueil</a></li>
<li class="active"><a href="explanation.html">L'explication</a></li>
<li><a href="examples.html">Exemples</a></li>
<li><a target="_blank" href="https://github.com/apimeal/apimeal">Le projet sur GitHub</a></li>
<li><a href="html">Doxygen</a></li>
</ul>
</div>
</div>
</div>
<!-- MAIN CONTENT -->
<div class="container">
<div class="explanation">
<h2>L'explication</h2>
<p>
L'APImeal se divise en 5 grandes parties représentant les principales étapes réalisé par le serveur HTTP.<br />
Chaque partie est composée d'un module correspondant à l'action principale et de un ou deux point(s) d'encrage(s) (hook).<br />
Chaque hook sert à effectuer de potentiels actions de pré ou post traitement.
</p>
<h4>Connection</h4>
<p>Ce module permet de gérer la connection d'un client et de récupérer les requètes envoyées</p>
<table class="table table-bordered table-striped">
<thead>
<tr>
<th class="name">Nom</th>
<th class="param">Paramètre(s)</th>
<th class="desc">Description</th>
<th class="exem">Exemple</th>
</tr>
</thead>
<tbody>
<tr>
<td class="hook-name">preConnection</td>
<td>IConnexion *, Error &</td>
<td>Appelé quand un client se connecte</td>
<td>Blacklist</td>
</tr>
<tr>
<td class="module-name">connection</td>
<td></td>
<td>Accepte la connexion d’un client</td>
<td></td>
</tr>
<tr>
<td class="hook-name">postConnection</td>
<td>IConnexion *, Error &</td>
<td>Gestion SSL</td>
<td>SSL</td>
</tr>
</tbody>
</table>
<h4>ParseRequest</h4>
<p>Ce module permet de parser les requètes envoyées ainsi que de les décoder et d'effectuer les potentiels URL Rewriting</p>
<table class="table table-bordered table-striped">
<thead>
<tr>
<th class="name">Nom</th>
<th class="param">Paramètre(s)</th>
<th class="desc">Description</th>
<th class="exem">Exemple</th>
</tr>
</thead>
<tbody>
<tr>
<td class="hook-name">preParseRequest</td>
<td>IHttpRequest *, Error &</td>
<td>Appelé pour décoder le charset</td>
<td>Decodage de la requète</td>
</tr>
<tr>
<td class="module-name">parseRequest</td>
<td></td>
<td>Parsing de la requête</td>
<td></td>
</tr>
<tr>
<td class="hook-name">postParseRequest</td>
<td>IHttpRequest *, Error &</td>
<td>Appelé à la fin du parsing du header HTTP</td>
<td>URL Rewriting</td>
</tr>
</tbody>
</table>
<h4>GetContent</h4>
<p>Ce module permet de récupérer et reformater le contenu de la requète</p>
<table class="table table-bordered table-striped">
<thead>
<tr>
<th class="name">Nom</th>
<th class="param">Paramètre(s)</th>
<th class="desc">Description</th>
<th class="exem">Exemple</th>
</tr>
</thead>
<tbody>
<tr>
<td class="module-name">getContent</td>
<td></td>
<td>Récuperation du contenu de la requête</td>
<td></td>
</tr>
<tr>
<td class="hook-name">contentModule</td>
<td>IHttpRequest *, Error &</td>
<td>Permet de modifié le contenu de la requète</td>
<td>Proxy</td>
</tr>
</tbody>
</table>
<h4>GenerateResponse</h4>
<p>Ce module permet de générer le contenue de la réponse ainsi que de la formater</p>
<table class="table table-bordered table-striped">
<thead>
<tr>
<th class="name">Nom</th>
<th class="param">Paramètre(s)</th>
<th class="desc">Description</th>
<th class="exem">Exemple</th>
</tr>
</thead>
<tbody>
<tr>
<td class="hook-name">CGIModule</td>
<td>IHttpResponse *, Error &</td>
<td>Gestion des CGI</td>
<td><a href="examples.html" title="Exemple CGI">Module CGI</a></td>
</tr>
<tr>
<td class="module-name">generateResponse</td>
<td></td>
<td>Génération du contenu de la réponse</td>
<td></td>
</tr>
<tr>
<td class="hook-name">postGenerateResponse</td>
<td>IHttpResponse *, Error &</td>
<td>Appelé pour encoder le contenu de la réponse</td>
<td>Encodage de la réponse</td>
</tr>
</tbody>
</table>
<h4>SendResponse</h4>
<p>Ce module permet d'envoyer la reponse au client</p>
<table class="table table-bordered table-striped">
<thead>
<tr>
<th class="name">Nom</th>
<th class="param">Paramètre(s)</th>
<th class="desc">Description</th>
<th class="exem">Exemple</th>
</tr>
</thead>
<tbody>
<tr>
<td class="hook-name">preSendRequest</td>
<td>IHttpResponse *, Error &</td>
<td>Gestion du SSL</td>
<td>SSL</td>
</tr>
<tr>
<td class="module-name">SendRequest</td>
<td></td>
<td>Envoi de la requête</td>
<td></td>
</tr>
</tbody>
</table>
</div>
</div>
<!-- FOOTER -->
<div class="container">
<hr />
<footer>
<p class="pull-right">
<iframe width="150px" src="//www.facebook.com/plugins/like.php?href=https%3A%2F%2Fwww.facebook.com%2FAPImeal&width&layout=button_count&action=like&show_faces=true&share=true&height=21&appId=566911539989395" scrolling="no" frameborder="0" style="border:none; overflow:hidden; height:21px;" allowTransparency="true"></iframe>
<a href="https://twitter.com/APImealZia" class="twitter-follow-button" data-show-count="false" data-lang="en" data-size="large">Follow @APImealZia</a>
<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="//platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>
<iframe src="http://ghbtns.com/github-btn.html?user=apimeal&repo=apimeal&type=watch&size=large"
allowtransparency="true" frameborder="0" scrolling="0" width="100px" height="30px"></iframe>
<iframe src="http://ghbtns.com/github-btn.html?user=apimeal&repo=apimeal&type=fork&size=large"
allowtransparency="true" frameborder="0" scrolling="0" width="100px" height="30px"></iframe>
</p>
<div>
<a href="http://www.epitech.net" target="_blank"><img class="epitech" src="Resources/images/epitech.gif" alt="Epitech" /></a>
<div class="info">
<p>APImeal : L'API qui vous simplifie la vie<br />
Par : seguin_s, lacroi_t, pillet_c, devaux_a, aubine_v, coutur_n
</div>
</div>
</footer>
</div>
</body>
</html>