// file: dt_cstr_2.cc
//

// isip include files
//
#include "decision_tree.h"
#include "decision_tree_constants.h"
 
// method: constructor
//
// arguments:
//    Dt_node* root: (input) the root node of this tree
//
// return: none
//
// this is the overloaded constructor to build the tree  
//
Decision_tree::Decision_tree(Dt_node* root_a) {

  // set the root node
  //
  root_d = root_a;

  num_leaf_d = 1;
  state_pos_d = 0;

  // set the thresholds
  //
  split_threshd_d = DT_DEFAULT_SPLIT_THRESHOLD;
  merge_threshd_d = DT_DEFAULT_MERGE_THRESHOLD;
  num_occ_threshd_d = DT_DEFAULT_NUM_OCC_THRESHOLD;

  // set the leaf nodes list
  //
  Link_node* node = new Link_node((void_p)root_a);  
  leaf_nodes_d = new Link_list();
  leaf_nodes_d ->insert_cc(node);
  
  // exit gracefully
  //
}
