Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConfigNode ¶
type ConfigNode struct { Name string Content string Parent *ConfigNode Children []*ConfigNode }
ConfigNode is a recursively defined n-ary tree
func Parse ¶
func Parse(r io.Reader) (*ConfigNode, error)
Parse reads a data source and converts the apache config file into a tree-based struct
func (*ConfigNode) Find ¶
func (c *ConfigNode) Find(name string) ([]*ConfigNode, error)
Find finds all elements in the subtree c where node.Name == name
func (*ConfigNode) FindOne ¶
func (c *ConfigNode) FindOne(name string) (*ConfigNode, error)
FindOne finds the first element in the subtree c where node.Name == name
func (*ConfigNode) String ¶
func (c *ConfigNode) String(level int) string
String prints out the contents of a Config node in an easy to read format
Click to show internal directories.
Click to hide internal directories.