// file: $isip/class/search/TrainNode/tnod_00.cc
// version: $Id: tnod_00.cc 9000 2003-01-23 20:00:34Z alphonso $
//

// isip include files
//
#include "TrainNode.h"

// method: default constructor
//
// arguments: none
//
// return: none
//
// this is the default constructor for the TrainNode class
//
TrainNode::TrainNode() {

  if (debug_level_d >= Integral::ALL) { 
    if (debug_level_d >= Integral::ALL) {     
      fprintf(stdout, "Constructor of train_node: %p\n", this);
      fflush(stdout);
    }
  }
    
  // initialize pointers and values
  //
  reference_d = (Context*)NULL;
  stat_model_d = (StatisticalModel*)NULL;

  // initialize member data
  //
  is_valid_d = false;
  is_alpha_valid_d = false;
  is_beta_valid_d = false;
  is_accum_valid_d = false;
  
  frame_d = DEF_TIMESTAMP;  
  beta_d = Integral::DB_LOG_MIN_VALUE;
  alpha_d = Integral::DB_LOG_MIN_VALUE;
  score_d = Integral::DB_LOG_MIN_VALUE;  
}

// method: copy constructor
//
// arguments:
//  const TrainNode& copy_node: (input) node to copy
//
// return: none
//
// this is the copy constructor for the TrainNode class
//
TrainNode::TrainNode(const TrainNode& copy_node_a) {

  if (debug_level_d >= Integral::ALL) { 
    if (debug_level_d >= Integral::ALL) {     
      fprintf(stdout, "Constructor of train_node: %p\n", this);
      fflush(stdout);
    }
  }
    
  // assign the node
  //
  assign(copy_node_a);
}

// constants: required constants such as class name
//
const String TrainNode::CLASS_NAME(L"TrainNode");

// constants: i/o related constants
//
const String TrainNode::DEF_PARAM(L"TrainNode");

// static instantiations: memory manager and debug level
//
MemoryManager TrainNode::mgr_d(sizeof(TrainNode), name());
Integral::DEBUG TrainNode::debug_level_d = Integral::NONE;
