Documentation ¶
Index ¶
- type DefaultResolver
- type MxResp
- type Resolver
- func (r Resolver) LookupAddress(ip string) ([]string, error)
- func (r Resolver) LookupCNAME(fqdn string) (string, error)
- func (r Resolver) LookupMX(fqdn string) ([]*MxResp, error)
- func (r Resolver) LookupTXT(fqdn string) ([]string, error)
- func (r Resolver) Reroute(address, network string) error
- func (r Resolver) Reset() error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DefaultResolver ¶
type DefaultResolver interface { LookupTXT(name string) ([]string, error) LookupAddress(name string) ([]string, error) LookupCNAME(name string) (string, error) LookupMX(name string) ([]*MxResp, error) Reroute(address, network string) error Reset() error }
func NewResolver ¶
func NewResolver() DefaultResolver
NewResolver creates and uses a default resolver
type Resolver ¶
type Resolver uint32
func (Resolver) LookupAddress ¶
LookupAddr performs a reverse lookup for the given address, returning a list of names mapping to that address and an error.
func (Resolver) LookupCNAME ¶
LookupCNAME returns the canonical name for the given host.
LookupCNAME does not return an error if the given name does not contain DNS "CNAME" records, as long as the name resolves to address records.
Click to show internal directories.
Click to hide internal directories.