This function allows you to register a callback function that is called after each tree is parsed. The signature of your function should be: bool someFunctionName(NxsFullTreeDescription &treeDesc, void * blob, NxsTreesBlock * treesB); where:
If your function returns false, then the trees block will not store. If your callback function returns true, then the tree will be stored. In either case the NxsTreesBlock will continue parsing after your function returns. This Callback hook is convenient for rejecting unwanted trees to save on memory, but it can also be used as an optimization. See the example executable in example/splitsinfile. This NCL client, uses this callback to store the splits from a trees as the TREES block is being parsed. It returns false in each case, so that the trees are not stored after they are used.
Definition at line 791 of file nxstreesblock.h. |