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`.`internet`.`protocol`.`_InstanceFactory``

class documentation

`class _InstanceFactory(ClientFactory): (source)`

View In Hierarchy

Factory used by ClientCreator.

Method | `__init__` | Undocumented
Method | `__repr__` | Undocumented
Method | `buildProtocol` | Return the pre-constructed protocol instance and arrange to fire the waiting `Deferred` to indicate success establishing the connection.
Method | `clientConnectionFailed` | Arrange to fire the waiting `Deferred` with the given failure to indicate the connection could not be established.
Method | `fire` | Clear `self.pending` to avoid a reference cycle and then invoke func with the value.
Class Variable | `noisy` | Undocumented
Instance Variable | `deferred` | The `Deferred` which represents this connection attempt and which will be fired when it succeeds or fails.
Instance Variable | `instance` | Undocumented
Instance Variable | `pending` | After a connection attempt succeeds or fails, a delayed call which will fire the `Deferred` representing this connection attempt.
Instance Variable | `reactor` | Undocumented

Inherited from `ClientFactory`:

Method | `clientConnectionLost` | Called when an established connection is lost.
Method | `startedConnecting` | Called when a connection has been started.

Inherited from `Factory` (via `ClientFactory`):

Class Method | `forProtocol` | Create a factory for the given protocol.
Method | `doStart` | Make sure startFactory is called.
Method | `doStop` | Make sure stopFactory is called.
Method | `logPrefix` | Describe this factory for log messages.
Method | `startFactory` | This will be called before I begin listening on a Port or Connector.
Method | `stopFactory` | This will be called before I stop listening on all Ports/Connectors.
Class Variable | `protocol` | Undocumented
Instance Variable | `numPorts` | Undocumented

def __init__(self, reactor, instance, deferred): (source)

Undocumented

def __repr__(self): (source)

Undocumented

Returns
`str` | Undocumented

def buildProtocol(self, addr): (source)
from `twisted.internet.interfaces.IProtocolFactory`
overrides `twisted.internet.protocol.Factory.buildProtocol`

Return the pre-constructed protocol instance and arrange to fire the waiting `Deferred` to indicate success establishing the connection.

def clientConnectionFailed(self, connector, reason): (source)
overrides `twisted.internet.protocol.ClientFactory.clientConnectionFailed`

Arrange to fire the waiting `Deferred` with the given failure to indicate the connection could not be established.

def fire(self, func, value): (source)

Clear `self.pending` to avoid a reference cycle and then invoke func with the value.

noisy: `bool` = (source)
overrides `twisted.internet.protocol.Factory.noisy`

Undocumented

deferred = (source)

The `Deferred` which represents this connection attempt and which will be fired when it succeeds or fails.

instance = (source)

Undocumented

pending = (source)

After a connection attempt succeeds or fails, a delayed call which will fire the `Deferred` representing this connection attempt.

reactor = (source)

Undocumented