// file: hist_debug_0.cc
//

// isip include files
//
#include "history.h"
#include "history_constants.h"

// method: debug_cc
//
// arguments:
//  FILE* fp: (input) a open file pointer
//  char_1* message: (input) a message to be displayed
//
// return: a logical_1 flag indicating success
//
logical_1 History::debug_cc(FILE *fp_a, char_1* message_a) {
  
  // dump the contents of the class to the file
  //
  fprintf(fp_a, "%s::%s histwords_d = %p\n", HISTORY_CLASS_NAME, message_a,
	  histwords_d);
  fprintf(fp_a, "%s::%s type_d = %c\n", HISTORY_CLASS_NAME, message_a,
	  type_d);

  // level and phone index
  //
  fprintf(fp_a, "%s::%s level_d = %ld\n", HISTORY_CLASS_NAME, message_a,
	  level_d);
  fprintf(fp_a, "%s::%s phone_index_d = %ld\n", HISTORY_CLASS_NAME, message_a,
	  phone_index_d);
  fprintf(fp_a, "%s::%s state_index_d = %ld\n", HISTORY_CLASS_NAME, message_a,
	  state_index_d);

  // path history data
  //
  fprintf(fp_a, "%s::%s hist_num_d = %ld\n", HISTORY_CLASS_NAME, message_a,
	  hist_num_d);
  fprintf(fp_a, "%s::%s prev_d = %p\n", HISTORY_CLASS_NAME, message_a,
	  prev_d);    
  fprintf(fp_a, "%s::%s prevsc_d = %p\n", HISTORY_CLASS_NAME, message_a,
	  prevsc_d);  
  
  // path data
  //
  fprintf(fp_a, "%s::%s frame_index_d = %ld\n", HISTORY_CLASS_NAME, message_a,
	  frame_index_d);
  fprintf(fp_a, "%s::%s score_d = %.4f\n", HISTORY_CLASS_NAME, message_a,
	  score_d);
  fprintf(fp_a, "%s::%s ref_count_d = %ld\n", HISTORY_CLASS_NAME, message_a,
	  ref_count_d);

  // exit gracefully
  //
  return ISIP_TRUE;
}
