Package pyamf :: Package remoting :: Package gateway :: Module django :: Class DjangoGateway |
[hide private]
[frames] | no frames]

# Class DjangoGateway

source code

An instance of this class is suitable as a Django view.

An example usage would be through `urlconf`:

       from django.conf.urls.defaults import *

       urlpatterns = patterns('',
           (r'^gateway/', 'yourproject.yourapp.gateway.gw_instance'),
       )

where `yourproject.yourapp.gateway.gw_instance` refers to an instance of this class.

Nested Classes | [hide private]
Inherited from `BaseGateway` (private): `_request_class`

Instance Methods | [hide private]
__init__(self, *args, **kwargs) x.__init__(...) initializes x; see x.__class__.__doc__ for signature | source code
Envelope |
getResponse(self, http_request, request) Processes the AMF request, returning an AMF response. | source code
`HTTPResponse` |
__call__(self, http_request) Processes and dispatches the request. | source code
Inherited from `BaseGateway`: `addService`, `authenticateRequest`, `callServiceRequest`, `getAuthenticator`, `getPreprocessor`, `getProcessor`, `getServiceRequest`, `mustExposeRequest`, `preprocessRequest`, `removeService` Inherited from `BaseGateway` (private): `_get_timezone_offset` Inherited from `object`: `__delattr__`, `__getattribute__`, `__hash__`, `__new__`, `__reduce__`, `__reduce_ex__`, `__repr__`, `__setattr__`, `__str__`

Instance Variables | [hide private]
`bool` | expose_request The standard Django view always has the request object as the first parameter.
Inherited from `BaseGateway`: `authenticator`, `debug`, `logger`, `preprocessor`, `services`, `strict`, `timezone_offset`

Properties | [hide private]
Inherited from `object`: `__class__`

Method Details | [hide private]

### __init__(self, *args, **kwargs) (Constructor) | source code
x.__init__(...) initializes x; see x.__class__.__doc__ for signature Overrides: object.__init__ (inherited documentation)

### getResponse(self, http_request, request) | source code
Processes the AMF request, returning an AMF response. Parameters: `http_request` (`HTTPRequest<django.core.http.HTTPRequest>`) - The underlying HTTP Request. `request` (Envelope) - The AMF Request. Returns: Envelope The AMF Response. Overrides: BaseGateway.getResponse

### __call__(self, http_request) (Call operator) | source code
Processes and dispatches the request. Parameters: `http_request` (`HTTPRequest`) - The `HTTPRequest` object. Returns: `HTTPResponse` The response to the request.

Instance Variable Details | [hide private]

### expose_request The standard Django view always has the request object as the first parameter. To disable this functionality, set this to `False`. Type: `bool`