Part of twisted.protocols.amp View Source View In Hierarchy
Known subclasses: twisted.protocols.amp._AmpParserBase
| Method | _wrapWithSerialization | Wrap aCallable with its command's argument de-serialization |
| Method | lookupFunction | Return a callable to invoke when executing the named command. |
| Method | dispatchCommand | A box with a _command key was received. |
| Parameters | aCallable | a callable with a 'command' attribute, designed to be called with keyword arguments. |
| command | the command class whose serialization to use. | |
| Returns | a 1-arg callable which, when invoked with an AmpBox, will deserialize the argument list and invoke appropriate user code for the callable's command, returning a Deferred which fires with the result or fails with an error. | |
| Parameters | name | the normalized name (from the wire) of the command. |
| Returns | a function that takes one argument (a Box) and returns a box, for handling the command identified by the given name. | |
A box with a _command key was received.
Dispatch it to a local handler call it.| Parameters | proto | an AMP instance. |
| box | an AmpBox to be dispatched. |