Go to the latest version of this document.
search in docstrings

Search bar offers the following options:

- Term presence. The below example searches for documents that must contain “foo”, might contain “bar” and must not contain “baz”: `+foo bar -baz`
- Wildcards. The below example searches for documents with words beginning with “foo”: `foo*`
- Search in specific fields. The following search matches all objects in "twisted.mail" that matches “search”: `+qname:twisted.mail.* +search`

  Possible fields: 'name', 'qname' (fully qualified name), 'docstring', and 'kind'. Last two fields are only applicable if "search in docstrings" is enabled.

- Fuzzy matches. The following search matches all documents that have a word within 1 edit distance of “foo”: `foo~1`

Results provided by Lunr.js

# ``twisted`.`mail`.`alias`.`ProcessAlias``

class documentation

`class ProcessAlias(AliasBase): (source)`

Implements interfaces: `twisted.mail.interfaces.IAlias`

View In Hierarchy

An alias which is handled by the execution of a program.

Method | `__init__` | No summary
Method | `__str__` | Build a string representation of this `ProcessAlias` instance.
Method | `createMessageReceiver` | Launch a process and create a message receiver to pass a message to the process.
Method | `spawnProcess` | Spawn a process.
Instance Variable | `path` | The arguments to pass to the process. The first string is the executable's name.
Instance Variable | `program` | The path of the program to be executed.
Instance Variable | `reactor` | A reactor which will be used to create and timeout the child process.

Inherited from `AliasBase`:

Method | `domain` | Return the domain associated with original address.
Method | `resolve` | Map this alias to its ultimate destination.
Instance Variable | `domains` | See `__init__`.
Instance Variable | `original` | The original address being aliased.

def __init__(self, path, *args): (source)
overrides `twisted.mail.alias.AliasBase.__init__`

Parameters
path:`bytes` | The command to invoke the program consisting of the path to the executable followed by any arguments.
*args:2-`tuple` of (0) `dict` mapping `bytes` to `IDomain` provider, (1) `bytes` | Arguments for `AliasBase.__init__`.

def __str__(self): (source)

Build a string representation of this `ProcessAlias` instance.

Returns
`bytes` | A string containing the command used to invoke the process.

def createMessageReceiver(self): (source)
from `twisted.mail.interfaces.IAlias`

Launch a process and create a message receiver to pass a message to the process.

Returns
`MessageWrapper` | A message receiver which delivers a message to the process.

def spawnProcess(self, proto, program, path): (source)

Spawn a process.

This wraps the `spawnProcess` method on `reactor` so that it can be customized for test purposes.

Parameters
proto:`IProcessProtocol` provider | An object which will be notified of all events related to the created process.
program:`bytes` | The full path name of the file to execute.
path:`list` of `bytes` | The arguments to pass to the process. The first string should be the executable's name.
Returns
`IProcessTransport` provider | A process transport.

path: `list` of `bytes` = (source)

The arguments to pass to the process. The first string is the executable's name.

program: `bytes` = (source)

The path of the program to be executed.

reactor: `IReactorTime` and `IReactorProcess` provider = (source)

A reactor which will be used to create and timeout the child process.