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`.`interfaces`.`IResolverSimple``

interface documentation

`class IResolverSimple(Interface): (source)`

Known subclasses: `twisted.internet.interfaces.IResolver`

Known implementations: `twisted.internet._resolver.ComplexResolverSimplifier`, `twisted.internet.base.BlockingResolver`, `twisted.internet.base.ThreadedResolver`

View In Hierarchy

Undocumented

Method | `getHostByName` | Resolve the domain name `name` into an IP address.

def getHostByName(name, timeout): (source)

Resolve the domain name `name` into an IP address.

Parameters
name:`str` | DNS name to resolve.
timeout:`Sequence[int]` | Number of seconds after which to reissue the query. When the last timeout expires, the query is considered failed.
Returns

`Deferred[str]`

The callback of the Deferred that is returned will be passed a string that represents the IP address of the specified name, or the errback will be called if the lookup times out. If multiple types of address records are associated with the name, A6 records will be returned in preference to AAAA records, which will be returned in preference to A records. If there are multiple records of the type to be returned, one will be selected at random.

Raises
`twisted.internet.defer.TimeoutError` | Raised (asynchronously) if the name cannot be resolved within the specified timeout period.