// file: $isip/class/search/SearchNode/snod_00.cc // // isip include files // #include "SearchNode.h" #include #include // method: default constructor // // arguments: none // // return: none // // this is the default constructor for the SearchNode class // SearchNode::SearchNode() { if (debug_level_d >= Integral::ALL) { fprintf(stdout, "Constructor of search_node: %p\n", this); fflush(stdout); } // initialize pointers and values // stat_model_d = (StatisticalModel*)NULL; level_d = (SearchLevel*)NULL; lex_tree_d = (LexicalTree*)NULL; model_id_d = DEF_MODEL_ID; symbol_id_d = DEF_SYMBOL_ID; timestamp_d = DEF_TIMESTAMP; score_d = INACTIVE_SCORE; // change the allocation mode of the trace and instance list // traces_d.setAllocationMode(DstrBase::USER); instances_d.setAllocationMode(DstrBase::USER); } // method: copy constructor // // arguments: // const SearchNode& copy_node: (input) node to copy // // return: none // // this is the copy constructor for the SearchNode class // SearchNode::SearchNode(const SearchNode& copy_node_a) { if (debug_level_d >= Integral::ALL) { fprintf(stdout, "Constructor of snode: %p\n", this); fflush(stdout); } // initialize pointers and values // stat_model_d = (StatisticalModel*)NULL; level_d = (SearchLevel*)NULL; lex_tree_d = (LexicalTree*)NULL; model_id_d = DEF_MODEL_ID; symbol_id_d = DEF_SYMBOL_ID; timestamp_d = DEF_TIMESTAMP; score_d = INACTIVE_SCORE; // change the allocation mode of the trace and instance list // traces_d.setAllocationMode(DstrBase::USER); instances_d.setAllocationMode(DstrBase::USER); // assign the node // assign(copy_node_a); } // constants: required constants such as class name // const String SearchNode::CLASS_NAME(L"SearchNode"); // constants: i/o related constants // const String SearchNode::DEF_PARAM(L"node"); // static instantiations: memory manager and debug level // MemoryManager SearchNode::mgr_d(sizeof(SearchNode), name()); Integral::DEBUG SearchNode::debug_level_d = Integral::NONE;