It also supports the following methods:
-.. classmethod:: DNSQuestion.getDO() -> bool
+.. classmethod:: DNSQuestion:getDO() -> bool
.. versionadded:: 1.2.0
:returns: true if the DO bit was set, false otherwise
+.. classmethod:: DNSQuestion:getTag(key) -> string
+
+ .. versionadded:: 1.2.0
+
+ Get the value of a tag stored into the DNSQuestion object.
+
+ :param string key: The tag's key
+ :returns: A table of tags, using strings as keys and values
+
+.. classmethod:: DNSQuestion:getTagArray() -> table
+
+ .. versionadded:: 1.2.0
+
+ Get all the tags stored into the DNSQuestion object.
+
+ :returns: The tag's value if it was set, an empty string otherwise
+
+.. classmethod:: DNSQuestion:sendTrap(reason)
+
+ .. versionadded:: 1.2.0
+
+ Send an SNMP trap.
+
+ :param string reason: An optional string describing the reason why this trap was sent
+
+.. classmethod:: DNSQuestion:setTag(key, value)
+
+ .. versionadded:: 1.2.0
+
+ Set a tag into the DNSQuestion object.
+
+ :param string key: The tag's key
+ :param string value: The tag's value
+
+.. classmethod:: DNSQuestion:setTagArray(tags)
+
+ .. versionadded:: 1.2.0
+
+ Set an array of tags into the DNSQuestion object.
+
+ :param table tags: A table of tags, using strings as keys and values
+
.. _DNSResponse:
DNSResponse object
This object represents a single protobuf message as emitted by :program:`dnsdist`.
+.. classmethod:: DNSDistProtoBufMessage:addResponseRR(name, type, class, ttl, blob)
+
+ .. versionadded:: 1.2.0
+
+ Add a response RR to the protobuf message.
+
+ :param string name: The RR name.
+ :param int type: The RR type.
+ :param int class: The RR class.
+ :param int ttl: The RR TTL.
+ :param string blob: The RR binary content.
+
.. classmethod:: DNSDistProtoBufMessage:setBytes(bytes)
Set the size of the query
:param int qtype: The qtype of the question
:param int qclass: The qclass of the question
+.. classmethod:: DNSDistProtoBufMessage:setProtobufResponseType(sec, usec)
+
+ .. versionadded:: 1.2.0
+
+ Change the protobuf response type from a query to a response, and optionally set the query time.
+
+ :param int sec: Optional query time in seconds.
+ :param int usec: Optional query time in additional micro-seconds.
+
.. classmethod:: DNSDistProtoBufMessage:setRequestor(address)
Set the requestor's address.
:param int rcode: The response code of the answer
+.. classmethod:: DNSDistProtoBufMessage:setTag(value)
+
+ .. versionadded:: 1.2.0
+
+ Add a tag to the list of tags.
+
+ :param string value: The tag value
+
+.. classmethod:: DNSDistProtoBufMessage:setTagArray(valueList)
+
+ .. versionadded:: 1.2.0
+
+ Add a list of tags.
+
+ :param table tags: A list of tags as strings
+
.. classmethod:: DNSDistProtoBufMessage:setTime(sec, usec)
Set the time at which the query or response has been received.