diagnose_class.cc

来自「这是一个从音频信号里提取特征参量的程序」· CC 代码 · 共 80 行

CC
80
字号
// file: $isip/util/diagnostics/diagnose_class/diagnose_class.cc// version: $Id: diagnose_class.cc,v 1.32 2000/12/20 23:08:33 hamaker Exp $// isip include files //#include "diagnose_class.h"//-----------------------------------------------------------------------------//// program: diagnose_class////  synopsis: DIAG_CLASS.exe [-debug DETAILED] [3]//    DIAG_CLASS denotes the class to be diagnosed//    [] denotes the optional arguments//      [-debug DETAILED] -- the debug level, default BRIEF//      [3] -- the diagnose times, default 1////   this is the utility for diagnosing the isip classes// //-----------------------------------------------------------------------------int main(int argc, char **argv) {    // set default values  //  Integral::DEBUG debug_level = Integral::BRIEF;  long iterations = 1;    // have the error handler display file and line number information  //  Error::setDebug(Integral::ALL);  // parse the command line parameters  //  readCmdline(argc, argv, debug_level, iterations);  // output the start testing information  //  SysString output(L"testing class ");  output.concat(DIAG_CLASS_NAME::name());  output.concat(L"\n");  Console::put(output);    // diagnose the class  //  boolean status = true;    for (long count = 0; count < iterations; count++) {    Console::increaseIndention();    status &= DIAG_CLASS_NAME::diagnose(debug_level);    Console::decreaseIndention();        // output the iteration count if there is more than 1 iteration    //    if (iterations > 1) {      SysString iteration_str(L"iteration ");      SysString count_str;      count_str.assign(count);      iteration_str.concat(count_str);      iteration_str.concat(L": passed");      Console::put(iteration_str);    }  }  // output the end testing information  //  output.clear();  if (status == true) {    output.assign(L"tests passed for class ");  }  else {    output.assign(L"tests failed for class ");  }  output.concat(DIAG_CLASS_NAME::name());  output.concat(L"\n");  Console::put(output);    // exit gracefully  //  return Integral::exit();}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?