rm -f MANIFEST
doc:
- epydoc -n dnspython -u http://www.dnspython.org \
+ epydoc -v -n dnspython -u http://www.dnspython.org \
dns/*.py dns/rdtypes/*.py dns/rdtypes/ANY/*.py \
dns/rdtypes/IN/*.py
@type text: str
@param origin: The domain in which the number should be constructed.
The default is e164.arpa.
- @type: dns.name.Name object or None
+ @type origin: dns.name.Name object or None
@rtype: dns.name.Name object
"""
parts = [d for d in text if d.isdigit()]
@type name: dns.name.Name object.
@param origin: A domain containing the ENUM domain name. The
name is relativized to this domain before being converted to text.
- @type: dns.name.Name object or None
+ @type origin: dns.name.Name object or None
@param want_plus_prefix: if True, add a '+' to the beginning of the
returned number.
@rtype: str
def __init__(self, otype):
"""Initialize an option.
- @param rdtype: The rdata type
- @type rdtype: int
+ @param otype: The rdata type
+ @type otype: int
"""
self.otype = otype
import dns.exception
def inet_ntoa(address):
+ """Convert an IPv4 address in network form to text form.
+
+ @param address: The IPv4 address
+ @type address: string
+ @returns: string
+ """
if len(address) != 4:
raise dns.exception.SyntaxError
return '%u.%u.%u.%u' % (ord(address[0]), ord(address[1]),
ord(address[2]), ord(address[3]))
def inet_aton(text):
+ """Convert an IPv4 address in text form to network form.
+
+ @param text: The IPv4 address
+ @type text: string
+ @returns: string
+ """
parts = text.split('.')
if len(parts) != 4:
raise dns.exception.SyntaxError
return time.time() + timeout
def _poll_for(fd, readable, writable, error, timeout):
- """
- @param fd: File descriptor (int).
- @param readable: Whether to wait for readability (bool).
- @param writable: Whether to wait for writability (bool).
- @param expiration: Deadline timeout (expiration time, in seconds (float)).
-
+ """Poll polling backend.
+ @param fd: File descriptor
+ @type fd: int
+ @param readable: Whether to wait for readability
+ @type readable: bool
+ @param writable: Whether to wait for writability
+ @type writable: bool
+ @param timeout: Deadline timeout (expiration time, in seconds)
+ @type timeout: float
@return True on success, False on timeout
"""
event_mask = 0
return bool(event_list)
def _select_for(fd, readable, writable, error, timeout):
- """
- @param fd: File descriptor (int).
- @param readable: Whether to wait for readability (bool).
- @param writable: Whether to wait for writability (bool).
- @param expiration: Deadline timeout (expiration time, in seconds (float)).
-
+ """Select polling backend.
+ @param fd: File descriptor
+ @type fd: int
+ @param readable: Whether to wait for readability
+ @type readable: bool
+ @param writable: Whether to wait for writability
+ @type writable: bool
+ @param timeout: Deadline timeout (expiration time, in seconds)
+ @type timeout: float
@return True on success, False on timeout
"""
rset, wset, xset = [], [], []
def __init__(self, max_size=100000):
"""Initialize a DNS cache.
- @param max_size: The maximum number of nodes to cache; the default is
- 100000. Must be > 1.
+ @param max_size: The maximum number of nodes to cache; the default is 100000. Must be > 1.
@type max_size: int
"""
self.data = {}
@param ttype: The token type
@type ttype: int
- @ivar value: The token value
+ @param value: The token value
@type value: string
- @ivar has_escape: Does the token value contain escapes?
+ @param has_escape: Does the token value contain escapes?
@type has_escape: bool
"""
self.ttype = ttype