Documentation ¶
Index ¶
- func MakeBlockListHostsReaderf(b *BlockList) func(line string) error
- func MakeBlockListReaderf(b *BlockList, default_qtype uint16) func(line string) error
- func NewLevel() *level
- type BlockEntry
- type BlockList
- func (b *BlockList) Add(name string, qtype uint16)
- func (b *BlockList) AddEntry(entry string, default_qtype uint16) error
- func (b *BlockList) AddHostsEntry(entry string) error
- func (b *BlockList) Count() int
- func (b *BlockList) Delete(qname string, qtype uint16) bool
- func (b *BlockList) DeleteEntry(entry string, default_qtype uint16) (bool, error)
- func (b *BlockList) DeleteTree(qname string) bool
- func (b *BlockList) Dump() (out []BlockEntry)
- func (b *BlockList) Match(qname string, qtype uint16) bool
- func (b *BlockList) PrintTree()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MakeBlockListReaderf ¶
Types ¶
type BlockEntry ¶
type BlockList ¶
func (*BlockList) AddHostsEntry ¶
Add line from hosts file (only add if this is 0.0.0.0)
Expected format is:
0.0.0.0 domain # comment (optional)
func (*BlockList) Count ¶
Note - this counts the number of block entries not the number of nodes (nodes with no block entries are not counted and if a single node has multiple block entries these are all counted)
func (*BlockList) DeleteEntry ¶
Add entry in format 'domain:qtype' (if qtype is missing use default)
func (*BlockList) DeleteTree ¶
Delete subtree under qname
Click to show internal directories.
Click to hide internal directories.