Merge pull request #191 from OriPekelman/master

Add GetText() method
This commit is contained in:
rivo 2019-01-13 13:08:21 +01:00 committed by GitHub
commit e5e361b9d7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 0 deletions

View File

@ -105,6 +105,11 @@ func (n *TreeNode) SetChildren(childNodes []*TreeNode) *TreeNode {
return n
}
// GetText returns this node's text.
func (n *TreeNode) GetText() string {
return n.text
}
// GetChildren returns this node's children.
func (n *TreeNode) GetChildren() []*TreeNode {
return n.children