def __init__(self, items=None):
"""Initialize the set.
- @param items: the initial set of items
- @type items: any iterable or None
+ *items*, an iterable or ``None``, the initial set of items.
"""
self.items = []
-# Copyright (C) 2003-2007, 2009-2011 Nominum, Inc.
+# Copyright (C) 2003-2017 Nominum, Inc.
#
# Permission to use, copy, modify, and distribute this software and its
# documentation for any purpose with or without fee is hereby granted,
class BadTTL(dns.exception.SyntaxError):
-
"""DNS TTL value is not well-formed."""
The BIND 8 units syntax for TTLs (e.g. '1w6d4h3m10s') is supported.
- @param text: the textual TTL
- @type text: string
- @raises dns.ttl.BadTTL: the TTL is not well-formed
- @rtype: int
+ *text*, a ``text``, the textual TTL.
+
+ Raises ``dns.ttl.BadTTL`` if the TTL is not well-formed.
+
+ Returns an ``int``.
"""
if text.isdigit():
.. autoexception:: dns.rdataset.DifferingCovers
.. autoexception:: dns.rdataset.IncompatibleTypes
+
+dns.ttl Exceptions
+------------------
+
+.. autoexception:: dns.ttl.BadTTL