7 .. function:: ntohs(netshort)
9 This subroutine converts values between the host and network byte order.
10 Specifically, **ntohs()** converts 16-bit quantities from network byte order to host byte order.
12 :param netshort: 16-bit short addr
13 :rtype: converted addr
19 .. function:: storeQueryInCache(qstate, qinfo, msgrep, is_referral)
21 Store pending query in local cache.
23 :param qstate: :class:`module_qstate`
24 :param qinfo: :class:`query_info`
25 :param msgrep: :class:`reply_info`
26 :param is_referal: integer
29 .. function:: invalidateQueryInCache(qstate, qinfo)
31 Invalidate record in local cache.
33 :param qstate: :class:`module_qstate`
34 :param qinfo: :class:`query_info`
40 .. function:: verbose(level, msg)
42 Log a verbose message, pass the level for this message.
43 No trailing newline is needed.
45 :param level: verbosity level for this message, compared to global verbosity setting.
46 :param msg: string message
48 .. function:: log_info(msg)
50 Log informational message. No trailing newline is needed.
52 :param msg: string message
54 .. function:: log_err(msg)
56 Log error message. No trailing newline is needed.
58 :param msg: string message
60 .. function:: log_warn(msg)
62 Log warning message. No trailing newline is needed.
64 :param msg: string message
66 .. function:: log_hex(msg, data, length)
68 Log a hex-string to the log. Can be any length.
69 performs mallocs to do so, slow. But debug useful.
71 :param msg: string desc to accompany the hexdump.
72 :param data: data to dump in hex format.
73 :param length: length of data.
75 .. function:: log_dns_msg(str, qinfo, reply)
79 :param str: string message
80 :param qinfo: :class:`query_info`
81 :param reply: :class:`reply_info`
83 .. function:: log_query_info(verbosity_value, str, qinf)
85 Log query information.
87 :param verbosity_value: see constants
88 :param str: string message
89 :param qinf: :class:`query_info`
91 .. function:: regional_log_stats(r)
93 Log regional statistics.
95 :param r: :class:`regional`
100 .. function:: strextstate(module_ext_state)
102 Debug utility, module external qstate to string.
104 :param module_ext_state: the state value.
105 :rtype: descriptive string.
107 .. function:: strmodulevent(module_event)
109 Debug utility, module event to string.
111 :param module_event: the module event value.
112 :rtype: descriptive string.
114 .. function:: ldns_rr_type2str(atype)
116 Convert RR type to string.
118 .. function:: ldns_rr_class2str(aclass)
120 Convert RR class to string.