Up

module Dns_resolver

: sig
#
type commfn = {
# txfn
: Dns.Buf.t -> unit Lwt.t;
# rxfn
: (Dns.Buf.t -> Dns.Packet.t option) -> Dns.Packet.t Lwt.t;
# timerfn
: unit -> unit Lwt.t;
# cleanfn
: unit -> unit Lwt.t;
}
#
val resolve : (module Dns.Protocol.CLIENT) -> ?alloc:(unit -> Dns.Buf.t) -> ?dnssec:bool -> commfn -> Dns.Packet.q_class -> Dns.Packet.q_type -> Dns.Name.domain_name -> Dns.Packet.t Lwt.t
#
val gethostbyname : ?alloc:(unit -> Dns.Buf.t) -> ?q_class:Dns.Packet.q_class -> ?q_type:Dns.Packet.q_type -> commfn -> string -> Ipaddr.t list Lwt.t
#
val gethostbyaddr : ?alloc:(unit -> Dns.Buf.t) -> ?q_class:Dns.Packet.q_class -> ?q_type:Dns.Packet.q_type -> commfn -> Ipaddr.V4.t -> string list Lwt.t
end