GETN_USE_CURR
#define GETN_USE_CURR(_TR_NAME) TreeNode _tmpNode = _TR_NAME; TreeNode _tmpSubNode = _TR_NAME; string _strTemp;
GETN_USE_CURR can direct reuse an already created treenode. It's mostly the same as GETN_USE, the only difference is GETN_USE_CURR provide a possibility to modify this reuse treenode, but NOT it's subnode.
EX1
#include <GetNbox.h> void getNewLabel( TreeNode &trN ) { GETN_USE_CURR(trN) TREE_ADD_LABEL("New Points"); } void GETN_USE_CURR_ex1() { GETN_TREE(testTree) GETN_CHECK(FitAllCurves, "Fit All Curves", 0) GETN_BEGIN_BRANCH(Fit, "Fitting Options")//Match GETN_END_BRANCH GETN_CHECK(FixIntercept, "Fix Intercept", 0) GETN_CHECK(FixSlope, "Fix Slope", 0) GETN_END_BRANCH(Fit) //Match GETN_BEGIN_BRANCH GETN_NUM(Points, "Points", 20) TreeNode trNode = testTree.Points; getNewLabel(trNode); if(GetNBox(testTree, NULL, NULL, NULL, NULL)) out_tree(testTree); }
GETN_USE
GetNBox.h