Package twisted :: Package web :: Module server :: Class Request
[frames | no frames]

Class Request

    Versioned --+    
                |    
    Componentized --+
                    |
Jellyable --+       |
            |       |
 Serializable --+   |
                |   |
         Copyable --+
                    |
          Request --+
                    |
                   Request

Known Subclasses:
Request

Method Summary
  __init__(self, *args, **kw)
  childLink(self, name)
Return the text that links to a child of the requested resource.
  connectionLost(self, reason)
connection was lost
  finish(self)
We are finished writing data.
  getRootURL(self)
Get a previously-remembered URL.
  getSession(self, sessionInterface)
  getStateToCopyFor(self, issuer)
  notifyFinish(self)
Notify when finishing the request
  prePathURL(self)
  process(self)
Process a request.
  processingFailed(self, reason)
  rememberRootURL(self)
Remember the currently-processed part of the URL for later recalling.
  render(self, resrc)
  sibLink(self, name)
Return the text that links to a sibling of the requested resource.
  URLPath(self)
  view_addCookie(self, issuer, k, v, **kwargs)
Remote version of addCookie; same interface.
  view_finish(self, issuer)
Remote version of finish; same interface.
  view_registerProducer(self, issuer, producer, streaming)
Remote version of registerProducer; same interface.
  view_setETag(self, issuer, tag)
Remote version of setETag; same interface.
  view_setHeader(self, issuer, k, v)
Remote version of setHeader; same interface.
  view_setLastModified(self, issuer, when)
Remote version of setLastModified; same interface.
  view_setResponseCode(self, issuer, code)
Remote version of setResponseCode; same interface.
  view_unregisterProducer(self, issuer)
  view_write(self, issuer, data)
Remote version of write; same interface.
    Inherited from Copyable
  getStateToCopy(self)
Gather state to send when I am serialized for a peer.
  getTypeToCopy(self)
Determine what type tag to send for me.
  getTypeToCopyFor(self, perspective)
Determine what type tag to send for me.
  jellyFor(self, jellier)
Assemble type tag and state to copy for this broker.
    Inherited from Serializable
  processUniqueID(self)
Return an ID which uniquely represents this object for this process.
    Inherited from Jellyable
  getStateFor(self, jellier)
    Inherited from Request
  __repr__(self)
  _authorize(self)
  _cleanup(self)
Called when have finished responding and are no longer queued.
  _sendError(self, code, resp)
  addCookie(self, k, v, expires, domain, path, max_age, comment, secure)
Set an outgoing HTTP cookie.
  getAllHeaders(self)
Return dictionary of all headers the request received.
  getClient(self)
  getClientIP(self)
  getCookie(self, key)
Get a cookie that was sent from the network.
  getHeader(self, key)
Get a header that was sent from the network.
  getHost(self)
Get my originally requesting transport's host.
  getPassword(self)
  getRequestHostname(self)
Get the hostname that the user passed in to the request.
  getUser(self)
  gotLength(self, length)
Called when HTTP channel got length of content in this request.
  handleContentChunk(self, data)
Write a chunk of data.
  isSecure(self)
  noLongerQueued(self)
Notify the object that it is no longer queued.
  parseCookies(self)
Parse cookie headers.
  redirect(self, url)
Utility function that does a redirect.
  registerProducer(self, producer, streaming)
Register a producer.
  requestReceived(self, command, path, version)
Called by channel when all data has been received.
  setETag(self, etag)
Set an entity tag for the outgoing response.
  setHeader(self, k, v)
Set an outgoing HTTP header.
  setHost(self, host, port, ssl)
Change the host and port the request thinks it's using.
  setLastModified(self, when)
Set the Last-Modified time for the response to this request.
  setResponseCode(self, code, message)
Set the HTTP response code.
  unregisterProducer(self)
Unregister the producer.
  write(self, data)
Write some data as a result of an HTTP request.
    Inherited from Componentized
  addAdapter(self, adapterClass, ignoreClass, registry)
Utility method that calls addComponent.
  addComponent(self, component, ignoreClass, registry)
Add a component to me, for all appropriate interfaces.
  getComponent(self, interface, registry, default)
Create or retrieve an adapter for the given interface.
  locateAdapterClass(self, klass, interfaceClass, default, registry)
  removeComponent(self, component)
Remove the given component from me entirely, for all interfaces for which it has been registered.
  setAdapter(self, interfaceClass, adapterClass)
  setComponent(self, interfaceClass, component)
  unsetComponent(self, interfaceClass)
Remove my component specified by the given interface class.
  upgradeToVersion1(self)
    Inherited from Versioned
  __getstate__(self, dict)
Get state, adding a version number to it on its way out.
  __setstate__(self, state)
  versionUpgrade(self)
(internal) Do a version upgrade.

Instance Variable Summary
    Inherited from Request
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']}. args: All of the arguments, including URL and POST arguments.
str method: The HTTP method that was used.
  path: The path only (arguments not included).
  received_headers: All received headers
str uri: The full URI that was requested (includes arguments).

Class Variable Summary
str __pychecker__ = 'unusednames=issuer'
NoneType appRootURL = None                                                                  
NoneType session = None                                                                  
NoneType site = None                                                                  
    Inherited from Jellyable
tuple __implements__ = (<class twisted.spread.interfaces.IJell...
    Inherited from Request
int _forceSSL = 0                                                                     
int chunked = 0                                                                     
str clientproto = '(no clientproto yet)'
int code = 200                                                                   
str code_message = 'OK'
NoneType etag = None                                                                  
int finished = 0                                                                     
NoneType lastModified = None                                                                  
NoneType producer = None                                                                  
int sentLength = 0                                                                     
int startedWriting = 0                                                                     
    Inherited from Componentized
int persistenceVersion = 1                                                                     
    Inherited from Versioned
tuple persistenceForgets = ()

Method Details

childLink(self, name)

Return the text that links to a child of the requested resource.

connectionLost(self, reason)

connection was lost
Overrides:
twisted.protocols.http.Request.connectionLost (inherited documentation)

finish(self)

We are finished writing data.
Overrides:
twisted.protocols.http.Request.finish (inherited documentation)

getRootURL(self)

Get a previously-remembered URL.

notifyFinish(self)

Notify when finishing the request
Returns:
A deferred. The deferred will be triggered when the request is finished -- with a None value if the request finishes successfully or with an error if the request is stopped by the client.

process(self)

Process a request.
Overrides:
twisted.protocols.http.Request.process

rememberRootURL(self)

Remember the currently-processed part of the URL for later recalling.

sibLink(self, name)

Return the text that links to a sibling of the requested resource.

view_addCookie(self, issuer, k, v, **kwargs)

Remote version of addCookie; same interface.

view_finish(self, issuer)

Remote version of finish; same interface.

view_registerProducer(self, issuer, producer, streaming)

Remote version of registerProducer; same interface. (requires a remote producer.)

view_setETag(self, issuer, tag)

Remote version of setETag; same interface.

view_setHeader(self, issuer, k, v)

Remote version of setHeader; same interface.

view_setLastModified(self, issuer, when)

Remote version of setLastModified; same interface.

view_setResponseCode(self, issuer, code)

Remote version of setResponseCode; same interface.

view_write(self, issuer, data)

Remote version of write; same interface.

Class Variable Details

__pychecker__

Type:
str
Value:
'unusednames=issuer'                                                   

appRootURL

Type:
NoneType
Value:
None                                                                  

session

Type:
NoneType
Value:
None                                                                  

site

Type:
NoneType
Value:
None                                                                  

Generated by Epydoc 2.0 on Sat May 15 20:07:56 2004 http://epydoc.sf.net