// Next step to next node which selector returns true.
// if selector is nil, then returns every node when iterating the trie
// return nil means no more node
Next step to next node which selector returns true.
if selector is nil, then returns every node when iterating the trie
return nil means no more node
// Next step to next node which selector returns true . // if selector is nil then returns every node when iterating the trie // return nil means no more node
func (it *nodeIterator) Next(selector NodeSelector) *node {
	it.lock.Lock()
	defer it.lock.Unlock()
	if it.stack.ended {
		return nil
	}
	return it.stack.depthFirstNextStep(it.trie, selector)
}
func ( it * nodeIterator ) Next ( selector NodeSelector ) * node { it . lock . Lock ( ) defer it . lock . Unlock ( ) if it . stack . ended { return nil } return it . stack . depthFirstNextStep ( it . trie , selector ) }
Next step to next node which selector returns true.
Next step to next node which selector returns true .
// return it.stack.depthFirstNextStep(nil)