static const wxCmdLineEntryDesc cmdLineDesc[] =
{
- { wxCMD_LINE_SWITCH, _T("M"), _T("Memory debug"), _T("Display memory debug message on exit ('object -S')") },
- { wxCMD_LINE_SWITCH, _T("d"), _T("debug"), _T("all messages on ('message all 9')") },
- { wxCMD_LINE_SWITCH, _T("c"), _T("console"), _T("open a console") },
- { wxCMD_LINE_SWITCH, _T("q"), _T("quiet"), _T("be quiet ('message max 0')") },
- { wxCMD_LINE_SWITCH, _T("h"), _T("help"), _T("print help on bbi or on workspace defined if any") },
- { wxCMD_LINE_SWITCH, _T("g"), _T("graphical-dialog"), _T("prompts the user for the parameter values using graphical dialog") },
- { wxCMD_LINE_SWITCH, _T("t"), _T("text-dialog"), _T("prompts the user for the parameter values in text mode") },
- { wxCMD_LINE_SWITCH, _T("N"), _T("no-console"), _T("do not show console (even on error)") },
- { wxCMD_LINE_PARAM, NULL, NULL, _T("input_file"), wxCMD_LINE_VAL_STRING, wxCMD_LINE_PARAM_OPTIONAL | wxCMD_LINE_PARAM_MULTIPLE },
+ { wxCMD_LINE_SWITCH, _T("h"), _T("help"), _T("print this help or help on the application defined in input bbs file if any") },
+ { wxCMD_LINE_SWITCH, _T("g"), _T("graphical-dialog"), _T("prompt the input parameter values using graphical dialog") },
+ { wxCMD_LINE_SWITCH, _T("t"), _T("text-dialog"), _T("prompt the input parameter values in text mode") },
+ { wxCMD_LINE_SWITCH, _T("c"), _T("console"), _T("open bbi console") },
+ { wxCMD_LINE_SWITCH, _T("N"), _T("no-console"), _T("never open bbi console even on error") },
+ { wxCMD_LINE_SWITCH, _T("q"), _T("quiet"), _T("be quiet (='message max 0')") },
+ { wxCMD_LINE_SWITCH, _T("d"), _T("debug"), _T("turn all messages on (='message all 9')") },
+ { wxCMD_LINE_SWITCH, _T("D"), _T("Debug"), _T("memory debug on exit (='debug -D')") },
+ { wxCMD_LINE_PARAM, NULL, NULL, _T("file [file [...]]"), wxCMD_LINE_VAL_STRING, wxCMD_LINE_PARAM_OPTIONAL | wxCMD_LINE_PARAM_MULTIPLE },
{ wxCMD_LINE_NONE }
};
bool wxBBIApp::OnCmdLineParsed(wxCmdLineParser& parser)
{
- if (parser.Found(_T("M")))
+ if (parser.Found(_T("D")))
{
bbtk::StaticInitTime::PrintObjectListInfo = true;
}
Program: bbtk
Module: $RCSfile: bbtkInterpreter.cxx,v $ $
Language: C++
- Date: $Date: 2008/04/25 07:33:17 $
- Version: $Revision: 1.64 $
+ Date: $Date: 2008/04/25 08:05:23 $
+ Version: $Revision: 1.65 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
info.help = "Shows a graphical view of a bbtk pipeline.\n- BlackBoxName : name of the box to view. Default '.' : current box.\n- BlackBoxNameType : name of the type of box to view, ex : 'workspace')";
mCommandDict[info.keyword] = info;
- info.keyword = "object";
+ info.keyword = "debug";
info.argmin = 0;
info.argmax = 1;
- info.code = cObject;
- info.syntax = "object <object name>";
- info.help = "Provides debug info on object <object name>";
+ info.code = cDebug;
+ info.syntax = "debug [expr|-C|-D]";
+ info.help = "Prints debug info on living bbtk objects containing the string 'expr' (default expr=''). -C checks the factory integrity. -D turns on objects debug info after main ends";
mCommandDict[info.keyword] = info;
/*
throw QuitException();
break;
- case cObject :
- if (words.size()==2) ObjectInfo(words[1]);
- else ObjectInfo("");
+ case cDebug :
+ if (words.size()==2) Debug(words[1]);
+ else Debug("");
break;
/* obsolete
case cWorkspace :
//==========================================================================
- void Interpreter::ObjectInfo(const std::string& name)
+ void Interpreter::Debug(const std::string& name)
{
if ((name.length()==2)&&(name[0]=='-'))
{
- if (name[1]=='S')
+ if (name[1]=='D')
{
bbtk::StaticInitTime::PrintObjectListInfo = true;
}
Program: bbtk
Module: $RCSfile: bbtkInterpreter.h,v $ $
Language: C++
- Date: $Date: 2008/04/22 09:40:11 $
- Version: $Revision: 1.28 $
+ Date: $Date: 2008/04/25 08:05:23 $
+ Version: $Revision: 1.29 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
cKind, // LG
cNewGUI, // LG
cWorkspace, // LG
- cObject
+ cDebug // LG
} CommandCodeType;
/// The structure storing the informations on a command
void NewGUI(const std::string& box,
const std::string& instanceName);
- void ObjectInfo(const std::string& name);
+ void Debug(const std::string& arg);
private:
if (PrintObjectListInfo)
{
std::cout << std::endl
- << "***************** main ended *******************"
+ << "************************** main ended *******************"
<< std::endl << std::endl;
Object::PrintObjectListInfo("");
}
std::cout << "**** "<< Object::GetObjectsCount()
<<" bbtk objects still alive after main ended"<<std::endl;
std::cout << "**** "
- <<"Rerun bbi with -M option or put 'object -S' in bbs file"
+ <<"Rerun bbi with -D option or put 'debug -D' in bbs file"
<<std::endl;
std::cout << "**** "
- <<"to view the object list "
+ <<"to view the objects list "
<<std::endl;
std::cout << "*********************************************************"
+ <<std::endl
<<std::endl;
}