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
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
|
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>twisted.web.proxy.ReverseProxyRequest</title>
<link rel="stylesheet" href="epydoc.css" type="text/css"></link>
</head>
<body bgcolor="white" text="black" link="blue" vlink="#204080"
alink="#204080">
<!-- =========== START OF NAVBAR =========== -->
<table class="navbar" border="0" width="100%" cellpadding="0" bgcolor="#a0c0ff" cellspacing="0">
<tr valign="center">
<th class="navbar"> <a class="navbar" href="twisted.html">Home</a> </th>
<th class="navbar"> <a class="navbar" href="trees.html">Trees</a> </th>
<th class="navbar"> <a class="navbar" href="indices.html">Index</a> </th>
<th class="navbar"> <a class="navbar" href="help.html">Help</a> </th>
<th class="navbar" align="right" width="100%">
<table border="0" cellpadding="0" cellspacing="0">
<tr><th class="navbar" align="center">
<p class="nomargin">
<a class="navbar" target="_top" href="http://twistedmatrix.com/">Twisted 1.3.0rc1</a>
</p></th></tr></table>
</th>
</tr>
</table>
<table width="100%" cellpadding="0" cellspacing="0">
<tr valign="top">
<td width="100%">
<font size="-1"><b class="breadcrumbs">
<a href="twisted.html">Package twisted</a> ::
<a href="twisted.web.html">Package web</a> ::
<a href="twisted.web.proxy.html">Module proxy</a> ::
Class ReverseProxyRequest
</b></font></br>
</td>
<td><table cellpadding="0" cellspacing="0">
<tr><td align="right"><font size="-2">[<a href="frames.html"target="_top">frames</a> | <a href="twisted.web.proxy.ReverseProxyRequest.html" target="_top">no frames</a>]</font></td></tr>
</table></td>
</tr></table>
<!-- =========== START OF CLASS DESCRIPTION =========== -->
<h2 class="class">Class ReverseProxyRequest</h2>
<pre class="base-tree">
<a href="twisted.protocols.http.Request.html"><code>Request</code></a> --+
|
<b>ReverseProxyRequest</b>
</pre><br />
<hr/>
Used by ReverseProxy to implement a simple reverse proxy.
<hr/>
<!-- =========== START OF METHOD SUMMARY =========== -->
<table class="summary" border="1" cellpadding="3" cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="summary">
<th colspan="2">Method Summary</th></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.web.proxy.ReverseProxyRequest.html#process" class="summary-sig-name"><code>process</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
<br />
Override in subclasses.</td></tr>
<tr bgcolor="#e8f0f8" class="group">
<th colspan="2"> Inherited from Request</th></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#__init__" class="summary-sig-name"><code>__init__</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>channel</span>,
<span class=summary-sig-arg>queued</span>)</span></code>
</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#__repr__" class="summary-sig-name"><code>__repr__</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#_authorize" class="summary-sig-name"><code>_authorize</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#_cleanup" class="summary-sig-name"><code>_cleanup</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
<br />
Called when have finished responding and are no longer queued.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#_sendError" class="summary-sig-name"><code>_sendError</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>code</span>,
<span class=summary-sig-arg>resp</span>)</span></code>
</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#addCookie" class="summary-sig-name"><code>addCookie</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>k</span>,
<span class=summary-sig-arg>v</span>,
<span class=summary-sig-arg>expires</span>,
<span class=summary-sig-arg>domain</span>,
<span class=summary-sig-arg>path</span>,
<span class=summary-sig-arg>max_age</span>,
<span class=summary-sig-arg>comment</span>,
<span class=summary-sig-arg>secure</span>)</span></code>
<br />
Set an outgoing HTTP cookie.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#connectionLost" class="summary-sig-name"><code>connectionLost</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>reason</span>)</span></code>
<br />
connection was lost</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#finish" class="summary-sig-name"><code>finish</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
<br />
We are finished writing data.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#getAllHeaders" class="summary-sig-name"><code>getAllHeaders</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
<br />
Return dictionary of all headers the request received.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#getClient" class="summary-sig-name"><code>getClient</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#getClientIP" class="summary-sig-name"><code>getClientIP</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#getCookie" class="summary-sig-name"><code>getCookie</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>key</span>)</span></code>
<br />
Get a cookie that was sent from the network.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#getHeader" class="summary-sig-name"><code>getHeader</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>key</span>)</span></code>
<br />
Get a header that was sent from the network.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#getHost" class="summary-sig-name"><code>getHost</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
<br />
Get my originally requesting transport's host.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#getPassword" class="summary-sig-name"><code>getPassword</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#getRequestHostname" class="summary-sig-name"><code>getRequestHostname</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
<br />
Get the hostname that the user passed in to the request.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#getUser" class="summary-sig-name"><code>getUser</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#gotLength" class="summary-sig-name"><code>gotLength</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>length</span>)</span></code>
<br />
Called when HTTP channel got length of content in this request.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#handleContentChunk" class="summary-sig-name"><code>handleContentChunk</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>data</span>)</span></code>
<br />
Write a chunk of data.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#isSecure" class="summary-sig-name"><code>isSecure</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#noLongerQueued" class="summary-sig-name"><code>noLongerQueued</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
<br />
Notify the object that it is no longer queued.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#parseCookies" class="summary-sig-name"><code>parseCookies</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
<br />
Parse cookie headers.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#redirect" class="summary-sig-name"><code>redirect</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>url</span>)</span></code>
<br />
Utility function that does a redirect.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#registerProducer" class="summary-sig-name"><code>registerProducer</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>producer</span>,
<span class=summary-sig-arg>streaming</span>)</span></code>
<br />
Register a producer.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#requestReceived" class="summary-sig-name"><code>requestReceived</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>command</span>,
<span class=summary-sig-arg>path</span>,
<span class=summary-sig-arg>version</span>)</span></code>
<br />
Called by channel when all data has been received.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#setETag" class="summary-sig-name"><code>setETag</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>etag</span>)</span></code>
<br />
Set an <a name="index-entity_tag"></a><i class="indexterm">entity
tag</i> for the outgoing response.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#setHeader" class="summary-sig-name"><code>setHeader</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>k</span>,
<span class=summary-sig-arg>v</span>)</span></code>
<br />
Set an outgoing HTTP header.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#setHost" class="summary-sig-name"><code>setHost</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>host</span>,
<span class=summary-sig-arg>port</span>,
<span class=summary-sig-arg>ssl</span>)</span></code>
<br />
Change the host and port the request thinks it's using.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#setLastModified" class="summary-sig-name"><code>setLastModified</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>when</span>)</span></code>
<br />
Set the <a name="index-Last_Modified"></a><i
class="indexterm">Last-Modified</i> time for the response to this
request.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#setResponseCode" class="summary-sig-name"><code>setResponseCode</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>code</span>,
<span class=summary-sig-arg>message</span>)</span></code>
<br />
Set the HTTP response code.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#unregisterProducer" class="summary-sig-name"><code>unregisterProducer</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
<br />
Unregister the producer.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><code><span class="summary-sig"><a href="twisted.protocols.http.Request.html#write" class="summary-sig-name"><code>write</code></a>(<span class=summary-sig-arg>self</span>,
<span class=summary-sig-arg>data</span>)</span></code>
<br />
Write some data as a result of an HTTP request.</td></tr>
</table><br />
<!-- =========== START OF INSTANCE VARIABLE SUMMARY =========== -->
<table class="summary" border="1" cellpadding="3" cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="summary">
<th colspan="2">Instance Variable Summary</th></tr>
<tr bgcolor="#e8f0f8" class="group">
<th colspan="2"> Inherited from Request</th></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">A mapping of strings (the argument names) to lists of
values. i.e., ?foo=bar&foo=baz&quux=spam results in
{'foo': ['bar', 'baz'], 'quux': ['spam']}.</font></td>
<td><b><a href="twisted.protocols.http.Request.html#args"><code>args</code></a></b>: All of the arguments, including URL and POST arguments.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"><code>str</code></font></td>
<td><b><a href="twisted.protocols.http.Request.html#method"><code>method</code></a></b>: The HTTP method that was used.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><b><a href="twisted.protocols.http.Request.html#path"><code>path</code></a></b>: The path only (arguments not included).</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"> </font></td>
<td><b><a href="twisted.protocols.http.Request.html#received_headers"><code>received_headers</code></a></b>: All received headers</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"><code>str</code></font></td>
<td><b><a href="twisted.protocols.http.Request.html#uri"><code>uri</code></a></b>: The full URI that was requested (includes arguments).</td></tr>
</table><br />
<!-- =========== START OF CLASS VARIABLE SUMMARY =========== -->
<table class="summary" border="1" cellpadding="3" cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="summary">
<th colspan="2">Class Variable Summary</th></tr>
<tr bgcolor="#e8f0f8" class="group">
<th colspan="2"> Inherited from Request</th></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"><code>tuple</code></font></td>
<td><b><a href="twisted.protocols.http.Request.html#__implements__"><code>__implements__</code></a></b> = <span title="(<class twisted.internet.interfaces.IConsumer at 0x824feb4>,)"><code>(<class twisted.internet.interfaces.ICo<span class="variable-ellipsis">...</span></code>
</span></td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"><code>int</code></font></td>
<td><b><a href="twisted.protocols.http.Request.html#_forceSSL"><code>_forceSSL</code></a></b> = <span title="0">0 </span></td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"><code>int</code></font></td>
<td><b><a href="twisted.protocols.http.Request.html#chunked"><code>chunked</code></a></b> = <span title="0">0 </span></td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"><code>str</code></font></td>
<td><b><a href="twisted.protocols.http.Request.html#clientproto"><code>clientproto</code></a></b> = <span title="'(no clientproto yet)'"><code><span class="variable-quote">'</span>(no clientproto yet)<span class="variable-quote">'</span> </code>
</span></td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"><code>int</code></font></td>
<td><b><a href="twisted.protocols.http.Request.html#code"><code>code</code></a></b> = <span title="200">200 </span></td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"><code>str</code></font></td>
<td><b><a href="twisted.protocols.http.Request.html#code_message"><code>code_message</code></a></b> = <span title="'OK'"><code><span class="variable-quote">'</span>OK<span class="variable-quote">'</span> </code>
</span></td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"><code>NoneType</code></font></td>
<td><b><a href="twisted.protocols.http.Request.html#etag"><code>etag</code></a></b> = <span title="None">None </span></td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"><code>int</code></font></td>
<td><b><a href="twisted.protocols.http.Request.html#finished"><code>finished</code></a></b> = <span title="0">0 </span></td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"><code>NoneType</code></font></td>
<td><b><a href="twisted.protocols.http.Request.html#lastModified"><code>lastModified</code></a></b> = <span title="None">None </span></td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"><code>NoneType</code></font></td>
<td><b><a href="twisted.protocols.http.Request.html#producer"><code>producer</code></a></b> = <span title="None">None </span></td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"><code>int</code></font></td>
<td><b><a href="twisted.protocols.http.Request.html#sentLength"><code>sentLength</code></a></b> = <span title="0">0 </span></td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1"><code>int</code></font></td>
<td><b><a href="twisted.protocols.http.Request.html#startedWriting"><code>startedWriting</code></a></b> = <span title="0">0 </span></td></tr>
</table><br />
<!-- =========== START OF METHOD DETAILS =========== -->
<table class="details" border="1" cellpadding="3" cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="details">
<th colspan="2">Method Details</th></tr>
</table>
<a name="process"></a>
<table width="100%" class="func-details" bgcolor="#e0e0e0"><tr><td>
<h3><span class="sig"><span class="sig-name">process</span>(<span class=sig-arg>self</span>)</span>
</h3>
<p>Override in subclasses.</p>
This method is not intended for users.
<dl><dt></dt><dd>
<dl><dt><b>Overrides:</b></dt>
<dd><a href="twisted.protocols.http.Request.html#process"><code>twisted.protocols.http.Request.process</code></a> <i>(inherited documentation)</i>
</dd>
</dl>
</dd></dl>
</td></tr></table>
<br />
<!-- =========== START OF NAVBAR =========== -->
<table class="navbar" border="0" width="100%" cellpadding="0" bgcolor="#a0c0ff" cellspacing="0">
<tr valign="center">
<th class="navbar"> <a class="navbar" href="twisted.html">Home</a> </th>
<th class="navbar"> <a class="navbar" href="trees.html">Trees</a> </th>
<th class="navbar"> <a class="navbar" href="indices.html">Index</a> </th>
<th class="navbar"> <a class="navbar" href="help.html">Help</a> </th>
<th class="navbar" align="right" width="100%">
<table border="0" cellpadding="0" cellspacing="0">
<tr><th class="navbar" align="center">
<p class="nomargin">
<a class="navbar" target="_top" href="http://twistedmatrix.com/">Twisted 1.3.0rc1</a>
</p></th></tr></table>
</th>
</tr>
</table>
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td align="left"><font size="-2">Generated by Epydoc 2.0 on Sat May 15 20:08:05 2004</font></td>
<td align="right"><a href="http://epydoc.sourceforge.net"
><font size="-2">http://epydoc.sf.net</font></a></td>
</tr>
</table>
</body>
</html>
|