Documentation ¶
Index ¶
- func SetRR(m *dns.Msg, rrs []RR)
- type Arbitrary
- func (a *Arbitrary) BatchLoad(entries []string) error
- func (a *Arbitrary) BatchLoadFiles(files []string) error
- func (a *Arbitrary) LoadFromFile(path string) error
- func (a *Arbitrary) LoadFromReader(r io.Reader) error
- func (a *Arbitrary) LoadFromText(s string) error
- func (a *Arbitrary) Lookup(q dns.Question) []RR
- func (a *Arbitrary) LookupMsg(m *dns.Msg) *dns.Msg
- type RR
- type Section
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Arbitrary ¶
type Arbitrary struct {
// contains filtered or unexported fields
}
func NewArbitrary ¶
func NewArbitrary() *Arbitrary
func (*Arbitrary) BatchLoad ¶
BatchLoad loads records from multiple entries. If an entry has a prefix "ext:", BatchLoad loads it as a file using LoadFromFile. Otherwise, BatchLoad loads it as a text using LoadFromText.
func (*Arbitrary) BatchLoadFiles ¶
BatchLoadFiles loads records from multiple files.
func (*Arbitrary) LoadFromFile ¶
LoadFromFile loads records from a file.
func (*Arbitrary) LoadFromReader ¶
LoadFromReader loads records from a textual io.Reader.
func (*Arbitrary) LoadFromText ¶
LoadFromText loads records from a string. Text format: [pattern] [qclass] [qtype] [section] [RFC 1035 resource record] [qclass] and [qtype] can be numerical. e.g. dns.google IN A ANSWER dns.google. IN A 8.8.8.8 example.com IN A NA example.com. IN SOA ns.example.com. username.example.com. ( 2020091025 7200 3600 1209600 3600 )