Classes | |
class | anyplaceholder |
Abstract class used by the any class to store values. More... | |
class | anyholder |
class | anyholder< ValueType * > |
specialization of anyholder for pointer types More... | |
class | any |
struct | thing |
The TypeTraits which validates any type. More... | |
struct | integer |
The TypeTraits which validates all integer types. More... | |
struct | floating_point |
The TypeTraits which validates all floating point number types. More... | |
struct | number |
The TypeTraits which validates all numerical types. More... | |
class | AtomicBlackBox |
Ancestor of all user defined (concrete) black boxes which are atomic (vs. complex boxes which are made up of other (atomic or complex) boxes). More... | |
class | AtomicBlackBoxDescriptor |
Structure containing the description of a AtomicBlackBox input (name, description, type, functor). More... | |
class | AtomicBlackBoxGetFunctor |
Abstract functor of the Get accessors of the inputs and outputs of a AtomicBlackBox. More... | |
class | AtomicBlackBoxSetFunctor |
Abstract functor of the Set accessors of the inputs and outputs of a AtomicBlackBox. More... | |
class | AtomicBlackBoxTGetFunctor |
Template for concrete functors of the Get accessors of the inputs and outputs of a AtomicBlackBox (inherits from bbtk::AtomicBlackBoxGetFunctor). More... | |
class | AtomicBlackBoxTSetFunctor |
Template for concrete functors of the Set accessors of the inputs and outputs of a AtomicBlackBox (inherits from bbtk::AtomicBlackBoxSetFunctor). More... | |
class | AtomicBlackBoxTSetFunctor< UBB, T *, TACCESS * > |
Template specialization of AtomicBlackBoxTSetFunctor for pointer types. More... | |
class | AtomicBlackBoxInputDescriptor |
Structure containing the description of a AtomicBlackBox input (name, description, type, functor). More... | |
class | AtomicBlackBoxOutputDescriptor |
Structure containing the description of a AtomicBlackBox output (name, description, type, functor). More... | |
struct | Void |
class | BlackBox |
Abstract black-box interface. More... | |
class | BlackBoxDescriptor |
(Abstract) Contains information on a BlackBox type (name, description, author, inputs, outputs) and is able to create an instance of it. More... | |
class | BlackBoxInputConnector |
class | BlackBoxInputDescriptor |
Abstract descriptor of an input of a black box. More... | |
class | BlackBoxInputOutputDescriptor |
Abstract descriptor of an input or an output of a black box (has a name, description, type and nature). More... | |
class | BlackBoxOutputConnector |
class | BlackBoxOutputDescriptor |
Abstract descriptor of an output of a black box (stores a name, a description and type). More... | |
class | ComplexBlackBox |
Abstract user defined black boxes. More... | |
class | ComplexBlackBoxDescriptor |
Describes a ComplexBlackBox (constituents, connections) and is able to create an instance of it. More... | |
class | ComplexBlackBoxInputDescriptor |
Structure containing the description of a ComplexBlackBox input (name, description, type, mapping). More... | |
class | ComplexBlackBoxOutputDescriptor |
Structure containing the description of a ComplexBlackBox output (name, description, type, mapping). More... | |
class | ConfigurationException |
class | ConfigurationFile |
DDD. More... | |
class | Connection |
DDD. More... | |
class | DataInfo |
Object storing informations on a data type : includes C++ type info (std::type_info) and a string describing the "nature" of the data (what is the content of the structure). More... | |
class | Exception |
class Exception : generic class for throwing any exception More... | |
class | Executer |
class Executer: level 0 of script execution More... | |
class | Factory |
Can load and unload dynamic libraries containing black boxes packages and create instances of the black boxes registered in the packages loaded. More... | |
class | Interpreter |
The bbtk language interpreter. More... | |
class | InterpreterUser |
class | InterpreterException |
class | InterpreterVirtual |
class | MessageManager |
Manages the messages displayed by bbtk. More... | |
class | Object |
class | StaticInitTime |
class | Package |
registers black boxes descriptors and is able to create instances of the black boxes registered. More... | |
struct | Qt |
class | QtBlackBox |
Widget black boxes. More... | |
class | QtBlackBoxDescriptor |
class | QtBlackBoxDialog |
struct | Dummy |
struct | System |
System related stuff. More... | |
class | Transcriptor |
class Transcriptor: level 0 of script C++ translation More... | |
class | TypeMapping |
class | Utilities |
Holds various usefull methods. More... | |
class | VirtualExec |
class VirtualExec: level 0 of script execution More... | |
class | WidgetBlackBox |
class | WidgetBlackBoxDescriptor |
class | WidgetBlackBoxWindow |
class | WxApp |
struct | Wx |
class | WxFrame |
class | WxDialog |
class | WxBlackBox |
Widget black boxes. More... | |
class | WxBlackBoxDescriptor |
class | WxGUICommandUser |
Abstract class which defines the callbacks invoked by WxGUICommand. More... | |
class | WxGUICommand |
GUI Component which provides a command input zone. More... | |
class | WxGUIConsole |
A console in which user can enter commands. More... | |
class | WxHtmlWindow |
class | WxGUIHtmlBrowserUser |
Abstract class which defines the callbacks invoked by WxGUIHtmlBrowser. More... | |
class | WxGUIHtmlBrowser |
class | WxGUIOutputMessagesUser |
Abstract class which defines the callbacks invoked by WxGUIOutputMessages. More... | |
class | WxGUIOutputMessages |
GUI Component which provides a command input zone. More... | |
class | WxGUIPackageBrowser2User |
Abstract class which defines the callbacks invoked by WxGUIPackageBrowser2. More... | |
class | WxGUIBlackBoxInfo |
class | WxGUIBlackBoxListUser |
class | WxGUIBlackBoxList |
class | WxGUIPackageBrowser2 |
A package browser panel. More... | |
class | WxGUIPackageBrowser2Window |
Browser2 in a frame. More... | |
class | WxGUIScriptingInterface |
A scripting interface window. More... | |
class | WxTextCtrlGettingKeyEvents |
class | WxGUITextEditorUser |
Abstract class which defines the callbacks invoked by WxGUITextEditor. More... | |
class | WxGUITextEditorPage |
class | WxGUITextEditor |
A text editor panel. More... | |
class | WxGUITextEditorWindow |
Editor in a frame. More... | |
class | WxStreamRedirector |
Redirects std::cout to a wxTextCtrl and optionally to printf also. More... | |
class | wxGUIEditorGraphicBBS |
class | wxGUIEditorGraphicContainer |
Functions | |
template<> | |
std::string | HumanTypeName< bbtk::any< bbtk::thing > > () |
template<> | |
std::string | HumanTypeName< bbtk::any< bbtk::thing > > (const bbtk::any< bbtk::thing > &) |
void | SubsBrackets (std::string &s) |
const std::string & | GetIOStatusString (IOStatus s) |
std::ostream & | operator<< (std::ostream &s, const DataInfo &d) |
dump in a stream | |
std::string | bbGetObjectDescription () |
void | PackageReleaseBlackBoxDescriptorInternal (Package::WeakPointer pack, const std::string &descname) |
void * | run_time_up_or_down_cast (const std::type_info &target_type, const std::type_info &source_type, const void *source_pointer) |
void * | run_time_up_or_down_cast (const std::type_info &target_type, const std::type_info &source_type, void *source_pointer) |
template<class T > | |
std::string | TypeName () |
Template method which returns the name of a type. | |
template<class T > | |
std::string | TypeName (const T &t) |
Template method which returns the name of the type of a variable. | |
template<> | |
std::string | TypeName< std::type_info > (const std::type_info &t) |
template<class T > | |
std::string | HumanTypeName () |
Template method which returns the human readable name of a type. | |
template<class T > | |
std::string | HumanTypeName (const T &t) |
Template method which returns the human readable name of the type of a variable. | |
template<> | |
std::string | HumanTypeName< std::type_info > (const std::type_info &t) |
template<> | |
std::string | HumanTypeName< std::string > () |
template<> | |
std::string | HumanTypeName< std::string > (const std::string &) |
template<> | |
std::string | HumanTypeName< signed char > () |
template<> | |
std::string | HumanTypeName< signed char > (const signed char &) |
template<> | |
std::string | HumanTypeName< signed short > () |
template<> | |
std::string | HumanTypeName< signed short > (const signed short &) |
template<> | |
std::string | HumanTypeName< signed int > () |
template<> | |
std::string | HumanTypeName< signed int > (const signed int &) |
template<> | |
std::string | HumanTypeName< unsigned char > () |
template<> | |
std::string | HumanTypeName< unsigned char > (const unsigned char &) |
template<> | |
std::string | HumanTypeName< unsigned short > () |
template<> | |
std::string | HumanTypeName< unsigned short > (const unsigned short &) |
template<> | |
std::string | HumanTypeName< unsigned int > () |
template<> | |
std::string | HumanTypeName< unsigned int > (const unsigned int &) |
template<> | |
std::string | HumanTypeName< float > () |
template<> | |
std::string | HumanTypeName< float > (const float &) |
template<> | |
std::string | HumanTypeName< double > () |
template<> | |
std::string | HumanTypeName< double > (const double &) |
template<> | |
std::string | HumanTypeName< bool > () |
template<> | |
std::string | HumanTypeName< bool > (const bool &) |
template<> | |
std::string | HumanTypeName< long > () |
template<> | |
std::string | HumanTypeName< long > (const long &) |
template<> | |
std::string | HumanTypeName< std::vector< int8_t > > () |
template<> | |
std::string | HumanTypeName< std::vector< int8_t > > (const std::vector< int8_t > &) |
template<> | |
std::string | HumanTypeName< std::vector< uint8_t > > () |
template<> | |
std::string | HumanTypeName< std::vector< uint8_t > > (const std::vector< uint8_t > &) |
template<> | |
std::string | HumanTypeName< std::vector< int16_t > > () |
template<> | |
std::string | HumanTypeName< std::vector< int16_t > > (const std::vector< int16_t > &) |
template<> | |
std::string | HumanTypeName< std::vector< uint16_t > > () |
template<> | |
std::string | HumanTypeName< std::vector< uint16_t > > (const std::vector< uint16_t > &) |
template<> | |
std::string | HumanTypeName< std::vector< int32_t > > () |
template<> | |
std::string | HumanTypeName< std::vector< int32_t > > (const std::vector< int32_t > &) |
template<> | |
std::string | HumanTypeName< std::vector< uint32_t > > () |
template<> | |
std::string | HumanTypeName< std::vector< uint32_t > > (const std::vector< uint32_t > &) |
template<> | |
std::string | HumanTypeName< std::vector< long > > () |
template<> | |
std::string | HumanTypeName< std::vector< long > > (const std::vector< long > &) |
template<> | |
std::string | HumanTypeName< std::vector< float > > () |
template<> | |
std::string | HumanTypeName< std::vector< float > > (const std::vector< float > &) |
template<> | |
std::string | HumanTypeName< std::vector< double > > () |
template<> | |
std::string | HumanTypeName< std::vector< double > > (const std::vector< double > &) |
template<> | |
std::string | HumanTypeName< std::vector< std::string > > () |
template<> | |
std::string | HumanTypeName< std::vector< std::string > > (const std::vector< std::string > &) |
const std::string & | GetVersion () |
int | get_app_path (char *pname, size_t pathsize) |
BBTK_BLACK_BOX_TEMPLATE_IMPLEMENTATION (WidgetBlackBox, AtomicBlackBox) | |
IMPLEMENT_APP_NO_MAIN (WxApp) | |
wxString | std2wx (const std::string &s) |
Conversion std::string to wxString. | |
std::string | wx2std (const wxString &s) |
Conversion wxString to std::string. | |
END_EVENT_TABLE () | |
int wxCALLBACK | MyCompareFunction (long item1, long item2, long WXUNUSED(sortData)) |
void | CleanString_0D (std::string &var) |
bool | GetTextOrClear (const XMLNode &node, std::string &var) |
std::string | GetErrorMessage (XMLResults *res, const std::string &filename) |
std::string bbtk::bbGetObjectDescription | ( | ) | [inline] |
bbtk::BBTK_BLACK_BOX_TEMPLATE_IMPLEMENTATION | ( | WidgetBlackBox | , | |
AtomicBlackBox | ||||
) |
void bbtk::CleanString_0D | ( | std::string & | var | ) |
Definition at line 39 of file bbtkXML.h.
References i.
Referenced by GetTextOrClear().
00040 { 00041 int i,size=var.length(); 00042 for (i=1 ; i<size ; i++ ) 00043 { 00044 if ((var[i-1]==13) && (var[i]==10) ) 00045 { 00046 var[i-1]=32; // space 00047 } //if 00048 } // for 00049 }
bbtk::END_EVENT_TABLE | ( | ) |
int bbtk::get_app_path | ( | char * | pname, | |
size_t | pathsize | |||
) |
Definition at line 618 of file bbtkUtilities.cxx.
Referenced by bbtk::Utilities::GetExecutablePath().
00619 { 00620 #ifdef LINUX 00621 /* Oddly, the readlink(2) man page says no NULL is appended. */ 00622 /* So you have to do it yourself, based on the return value: */ 00623 pathsize --; /* Preserve a space to add the trailing NULL */ 00624 long result = readlink("/proc/self/exe", pname, pathsize); 00625 if (result > 0) 00626 { 00627 pname[result] = 0; /* add the #@!%ing NULL */ 00628 00629 if ((access(pname, 0) == 0)) 00630 return 0; /* file exists, return OK */ 00631 /*else name doesn't seem to exist, return FAIL (falls 00632 through) */ 00633 } 00634 #endif /* LINUX */ 00635 00636 #ifdef WIN32 00637 long result = GetModuleFileName(NULL, pname, pathsize); 00638 if (result > 0) 00639 { 00640 /* fix up the dir slashes... */ 00641 int len = strlen(pname); 00642 int idx; 00643 for (idx = 0; idx < len; idx++) 00644 { 00645 if (pname[idx] == '\\') pname[idx] = '/'; 00646 } 00647 00648 for (idx = len-1; idx >=0 ; idx--) 00649 { 00650 if (pname[idx] == '/') 00651 { 00652 pname[idx+1] = '\0'; 00653 idx = -1; 00654 } 00655 } 00656 00657 if ((access(pname, 0) == 0)) 00658 return 0; /* file exists, return OK */ 00659 /*else name doesn't seem to exist, return FAIL (falls 00660 through) */ 00661 } 00662 #endif /* WIN32 */ 00663 00664 #ifdef SOLARIS 00665 char *p = getexecname(); 00666 if (p) 00667 { 00668 /* According to the Sun manpages, getexecname will 00669 "normally" return an */ 00670 /* absolute path - BUT might not... AND that IF it is not, 00671 pre-pending */ 00672 /* getcwd() will "usually" be the correct thing... Urgh! 00673 */ 00674 00675 /* check pathname is absolute (begins with a / ???) */ 00676 if (p[0] == '/') /* assume this means we have an 00677 absolute path */ 00678 { 00679 strncpy(pname, p, pathsize); 00680 if ((access(pname, 0) == 0)) 00681 return 0; /* file exists, return OK */ 00682 } 00683 else /* if not, prepend getcwd() then check if file 00684 exists */ 00685 { 00686 getcwd(pname, pathsize); 00687 long result = strlen(pname); 00688 strncat(pname, "/", (pathsize - result)); 00689 result ++; 00690 strncat(pname, p, (pathsize - result)); 00691 00692 if ((access(pname, 0) == 0)) 00693 return 0; /* file exists, return OK */ 00694 /*else name doesn't seem to exist, return FAIL 00695 (falls through) */ 00696 } 00697 } 00698 #endif /* SOLARIS */ 00699 00700 #ifdef MACOSX /* assume this is OSX */ 00701 /* 00702 from http://www.hmug.org/man/3/NSModule.html 00703 00704 extern int _NSGetExecutablePath(char *buf, unsigned long 00705 *bufsize); 00706 00707 _NSGetExecutablePath copies the path of the executable 00708 into the buffer and returns 0 if the path was successfully 00709 copied in the provided buffer. If the buffer is not large 00710 enough, -1 is returned and the expected buffer size is 00711 copied in *bufsize. Note that _NSGetExecutablePath will 00712 return "a path" to the executable not a "real path" to the 00713 executable. That is the path may be a symbolic link and 00714 not the real file. And with deep directories the total 00715 bufsize needed could be more than MAXPATHLEN. 00716 */ 00717 int status = -1; 00718 char *given_path = (char*)malloc(MAXPATHLEN * 2); 00719 if (!given_path) return status; 00720 00721 uint32_t npathsize = MAXPATHLEN * 2; 00722 long result = _NSGetExecutablePath(given_path, &npathsize); 00723 if (result == 0) 00724 { /* OK, we got something - now try and resolve the real path... 00725 */ 00726 if (realpath(given_path, pname) != NULL) 00727 { 00728 if ((access(pname, 0) == 0)) 00729 status = 0; /* file exists, return OK */ 00730 } 00731 } 00732 free (given_path); 00733 return status; 00734 #endif /* MACOSX */ 00735 00736 return -1; /* Path Lookup Failed */ 00737 }
std::string bbtk::GetErrorMessage | ( | XMLResults * | res, | |
const std::string & | filename | |||
) |
Definition at line 73 of file bbtkXML.h.
References XMLResults::error, XMLNode::getError(), XMLResults::nColumn, and XMLResults::nLine.
Referenced by bbtk::ConfigurationFile::AddPackagePathsAndWrite(), and bbtk::ConfigurationFile::Read().
00074 { 00075 std::ostringstream str; 00076 str << XMLNode::getError(res->error); 00077 str << " [line " << res->nLine << ", col "<<res->nColumn<<"] "; 00078 str << " file "<<filename; 00079 return str.str(); 00080 }
const std::string& bbtk::GetIOStatusString | ( | IOStatus | s | ) |
Definition at line 52 of file bbtkConnection.cxx.
References IOSTATUS_STRING.
Referenced by bbtk::BlackBox::bbComputePostProcessStatus(), bbtk::BlackBox::bbPrintHelp(), bbtk::BlackBox::bbSetStatusAndPropagate(), bbtk::BlackBox::bbUpdateInputs(), bbtk::Connection::RecursiveExecute(), and bbtk::BlackBoxOutputConnector::SignalChange().
bool bbtk::GetTextOrClear | ( | const XMLNode & | node, | |
std::string & | var | |||
) | [inline] |
Definition at line 52 of file bbtkXML.h.
References CleanString_0D(), XMLNode::getClear(), XMLNode::getText(), XMLClear::lpszValue, XMLNode::nClear(), and XMLNode::nText().
Referenced by bbtk::ConfigurationFile::Read().
00053 { 00054 if (node.nText()>0) 00055 { 00056 var = node.getText(); 00057 CleanString_0D(var); 00058 return true; 00059 } 00060 else if (node.nClear()>0) 00061 { 00062 var = node.getClear().lpszValue; 00063 CleanString_0D(var); 00064 return true; 00065 } 00066 else 00067 { 00068 return false; 00069 } 00070 }
const std::string& bbtk::GetVersion | ( | ) | [inline] |
Definition at line 144 of file bbtkSystem.h.
References BBTK_STRINGIFY_SYMBOL.
Referenced by bbtk::ConfigurationFile::InitializeDotBbtkStructure(), bbtk::Package::OpenDynamicLibrary(), and WxProcessCmdLine::Process().
00145 { 00146 static const std::string v(BBTK_STRINGIFY_SYMBOL(BBTK_VERSION)); 00147 return v; 00148 }
std::string bbtk::HumanTypeName | ( | const T & | t | ) | [inline] |
Template method which returns the human readable name of the type of a variable.
Definition at line 136 of file bbtkRTTI.h.
References TypeName().
00137 { return TypeName(t); }
std::string bbtk::HumanTypeName | ( | ) | [inline] |
Template method which returns the human readable name of a type.
Definition at line 132 of file bbtkRTTI.h.
Referenced by bbtk::any< TypeTraits >::any(), bbtk::any< TypeTraits >::get(), bbtk::any< TypeTraits >::get_pointer(), bbtk::any< TypeTraits >::get_pointer_to(), bbtk::ComplexBlackBoxOutputDescriptor::GetHumanTypeName(), bbtk::ComplexBlackBoxInputDescriptor::GetHumanTypeName(), bbtk::any< TypeTraits >::operator=(), bbtk::Connection::TransferData(), and bbtk::any< TypeTraits >::unsafe_get().
std::string bbtk::HumanTypeName< bbtk::any< bbtk::thing > > | ( | const bbtk::any< bbtk::thing > & | ) | [inline] |
std::string bbtk::HumanTypeName< bbtk::any< bbtk::thing > > | ( | ) | [inline] |
std::string bbtk::HumanTypeName< bool > | ( | const bool & | ) | [inline] |
std::string bbtk::HumanTypeName< bool > | ( | ) | [inline] |
Definition at line 161 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< double > | ( | const double & | ) | [inline] |
std::string bbtk::HumanTypeName< double > | ( | ) | [inline] |
Definition at line 160 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< float > | ( | const float & | ) | [inline] |
std::string bbtk::HumanTypeName< float > | ( | ) | [inline] |
Definition at line 159 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< long > | ( | const long & | ) | [inline] |
std::string bbtk::HumanTypeName< long > | ( | ) | [inline] |
Definition at line 162 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< signed char > | ( | const signed char & | ) | [inline] |
std::string bbtk::HumanTypeName< signed char > | ( | ) | [inline] |
Definition at line 153 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< signed int > | ( | const signed int & | ) | [inline] |
std::string bbtk::HumanTypeName< signed int > | ( | ) | [inline] |
Definition at line 155 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< signed short > | ( | const signed short & | ) | [inline] |
std::string bbtk::HumanTypeName< signed short > | ( | ) | [inline] |
Definition at line 154 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< std::string > | ( | const std::string & | ) | [inline] |
std::string bbtk::HumanTypeName< std::string > | ( | ) | [inline] |
std::string bbtk::HumanTypeName< std::type_info > | ( | const std::type_info & | t | ) | [inline] |
Specialisation of TypeName when the type passed is already a type_info : The user does not want to know the type of the type_info class but of the class whose type_info is passed !
std::string bbtk::HumanTypeName< std::vector< double > > | ( | const std::vector< double > & | ) | [inline] |
std::string bbtk::HumanTypeName< std::vector< double > > | ( | ) | [inline] |
Definition at line 180 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< std::vector< float > > | ( | const std::vector< float > & | ) | [inline] |
std::string bbtk::HumanTypeName< std::vector< float > > | ( | ) | [inline] |
Definition at line 179 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< std::vector< int16_t > > | ( | const std::vector< int16_t > & | ) | [inline] |
std::string bbtk::HumanTypeName< std::vector< int16_t > > | ( | ) | [inline] |
Definition at line 174 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< std::vector< int32_t > > | ( | const std::vector< int32_t > & | ) | [inline] |
std::string bbtk::HumanTypeName< std::vector< int32_t > > | ( | ) | [inline] |
Definition at line 176 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< std::vector< int8_t > > | ( | const std::vector< int8_t > & | ) | [inline] |
std::string bbtk::HumanTypeName< std::vector< int8_t > > | ( | ) | [inline] |
std::string bbtk::HumanTypeName< std::vector< long > > | ( | const std::vector< long > & | ) | [inline] |
std::string bbtk::HumanTypeName< std::vector< long > > | ( | ) | [inline] |
Definition at line 178 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< std::vector< std::string > > | ( | const std::vector< std::string > & | ) | [inline] |
std::string bbtk::HumanTypeName< std::vector< std::string > > | ( | ) | [inline] |
Definition at line 181 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< std::vector< uint16_t > > | ( | const std::vector< uint16_t > & | ) | [inline] |
std::string bbtk::HumanTypeName< std::vector< uint16_t > > | ( | ) | [inline] |
Definition at line 175 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< std::vector< uint32_t > > | ( | const std::vector< uint32_t > & | ) | [inline] |
std::string bbtk::HumanTypeName< std::vector< uint32_t > > | ( | ) | [inline] |
Definition at line 177 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< std::vector< uint8_t > > | ( | const std::vector< uint8_t > & | ) | [inline] |
std::string bbtk::HumanTypeName< std::vector< uint8_t > > | ( | ) | [inline] |
Definition at line 173 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< unsigned char > | ( | const unsigned char & | ) | [inline] |
std::string bbtk::HumanTypeName< unsigned char > | ( | ) | [inline] |
Definition at line 156 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< unsigned int > | ( | const unsigned int & | ) | [inline] |
std::string bbtk::HumanTypeName< unsigned int > | ( | ) | [inline] |
Definition at line 158 of file bbtkRTTI.h.
std::string bbtk::HumanTypeName< unsigned short > | ( | const unsigned short & | ) | [inline] |
std::string bbtk::HumanTypeName< unsigned short > | ( | ) | [inline] |
Definition at line 157 of file bbtkRTTI.h.
bbtk::IMPLEMENT_APP_NO_MAIN | ( | WxApp | ) |
int wxCALLBACK bbtk::MyCompareFunction | ( | long | item1, | |
long | item2, | |||
long | WXUNUSEDsortData | |||
) |
Definition at line 101 of file bbtkWxGUIPackageBrowser2.cxx.
00102 { 00103 // inverse the order 00104 if (item1 < item2) 00105 return -1; 00106 if (item1 > item2) 00107 return 1; 00108 00109 return 0; 00110 }
std::ostream& bbtk::operator<< | ( | std::ostream & | s, | |
const DataInfo & | d | |||
) | [inline] |
dump in a stream
Definition at line 90 of file bbtkData.h.
References bbtk::DataInfo::GetNature(), bbtk::DataInfo::GetType(), and TypeName().
00091 { 00092 s << "<" << TypeName(d.GetType()) << "("<< d.GetNature()<<")>"; 00093 return s; 00094 }
void bbtk::PackageReleaseBlackBoxDescriptorInternal | ( | Package::WeakPointer | pack, | |
const std::string & | descname | |||
) |
Definition at line 121 of file bbtkPackage.cxx.
References bbtkDebugMessage, and bbtkendl.
Referenced by bbtk::Package::Release(), and bbtk::Package::ReleaseBlackBoxDescriptor().
00123 { 00124 // Try to release descriptor 00125 std::string packname = pack.lock()->GetName(); 00126 00127 bbtkDebugMessage("package",5,"--- Releasing descriptor '" 00128 <<packname<<"::"<<descname<<"'"<<bbtkendl); 00129 00130 00131 Package::DescriptorMapType::iterator desc = 00132 pack.lock()->GetDescriptorMap().find(descname); 00133 if (desc == pack.lock()->GetDescriptorMap().end()) 00134 { 00135 bbtkDebugMessage("package",5, 00136 " Descriptor has already been released" 00137 <<bbtkendl); 00138 return; 00139 } 00140 // bbtkDebugMessage("package",3, 00141 // " Trying unreferencing it ... "<<std::endl); 00142 BlackBoxDescriptor::WeakPointer pdesc = desc->second; 00143 desc->second.reset(); 00144 // if it is dead : remove it 00145 if (pdesc.expired()) 00146 { 00147 bbtkDebugMessage("package",2," ==> '"<<packname<<"::"<<descname<<"' Descriptor expired"<<bbtkendl); 00148 if (pack.expired()) 00149 { 00150 bbtkDebugMessage("package",2, 00151 " ... and caused its package death" 00152 <<bbtkendl); 00153 return; 00154 } // pack.expired 00155 desc = pack.lock()->GetDescriptorMap().find(descname); 00156 if (desc != pack.lock()->GetDescriptorMap().end()) pack.lock()->GetDescriptorMap().erase(desc); 00157 } else { //pdesc.expired 00158 bbtkDebugMessage("package",5," ... Descriptor still alive (" 00159 <<pdesc.use_count()<<" refs)" 00160 <<bbtkendl); 00161 pack.lock()->GetDescriptorMap()[descname] = pdesc.lock(); 00162 } // pdesc.expired 00163 }
void* bbtk::run_time_up_or_down_cast | ( | const std::type_info & | target_type, | |
const std::type_info & | source_type, | |||
void * | source_pointer | |||
) |
Definition at line 58 of file bbtkRTTI.cxx.
References bbtkDebugMessage, bbtkWarning, and TypeName().
00062 { 00063 bbtkDebugMessage("data",5, 00064 "run_time_up_or_down_cast : Casting pointer to '" 00065 << TypeName(typeid(*(Dummy*)source_pointer)) 00066 << "' from " << TypeName(source_type) 00067 << " to " << TypeName(target_type) << std::endl); 00068 00069 void* target_pointer = 0; 00070 #if __GNUC__ > 3 || \ 00071 (__GNUC__ == 3 && (__GNUC_MINOR__ > 1 || \ 00072 (__GNUC_MINOR__ == 1 && \ 00073 __GNUC_PATCHLEVEL__ > 0))) 00074 00075 const abi::__class_type_info* targetTI = 00076 (const abi::__class_type_info *)( &(target_type)); 00077 00078 bbtkDebugMessage("data",7," * source = "<<source_pointer<<std::endl); 00079 00080 void* tmp = source_pointer; 00081 if (source_type.__do_upcast(targetTI,&tmp)) 00082 { 00083 target_pointer = tmp; 00084 } 00085 else 00086 { 00087 bbtkDebugMessage("data",7, 00088 " * upcast failed : trying dynamic down cast" 00089 <<std::endl); 00090 const abi::__class_type_info* sourceTI = 00091 (const abi::__class_type_info *)( &(source_type)); 00092 00093 00094 target_pointer = abi::__dynamic_cast(source_pointer, 00095 sourceTI, 00096 targetTI, 00097 -1); 00098 } 00099 00100 bbtkDebugMessage("data",7," * target = "<<target_pointer<<std::endl); 00101 00102 #else 00103 bbtkWarning("run_time_up_or_down_cast not impl. on Win : to do"); 00104 // target_pointer = __RTDynamicCast(source_pointer, 0, source_type, target_type, 0); 00105 #endif 00106 return target_pointer; 00107 00108 }
void* bbtk::run_time_up_or_down_cast | ( | const std::type_info & | target_type, | |
const std::type_info & | source_type, | |||
const void * | source_pointer | |||
) |
Definition at line 48 of file bbtkRTTI.cxx.
Referenced by bbtk::anyholder< ValueType * >::get_pointer_to().
00052 { 00053 return run_time_up_or_down_cast(target_type, 00054 source_type, 00055 const_cast<void*>(source_pointer)); 00056 }
wxString bbtk::std2wx | ( | const std::string & | s | ) | [inline] |
Conversion std::string to wxString.
Definition at line 138 of file bbtkWx.h.
Referenced by bbtk::WxBlackBox::bbCreateDialogWindow(), bbtk::WxBlackBox::bbCreateFrameWindow(), bbtk::WxGUITextEditor::CloseCurrentPage(), bbtk::Executer::DefineInput(), bbtk::WxGUIScriptingInterface::DoRegenerateBoxesLists(), bbtk::WxGUIScriptingInterface::DoRegeneratePackageDoc(), bbtk::WxGUIHtmlBrowser::GoTo(), bbtk::WxGUIBlackBoxList::Insert(), bbtk::WxGUIBlackBoxInfo::InsertInputOutput(), bbtk::WxGUITextEditorPage::Load(), bbtk::WxGUIScriptingInterface::LoadPerspective(), bbtk::WxGUITextEditor::NewPage(), bbtk::WxGUIBlackBoxList::OnBeginDrag(), bbtk::WxGUIConsole::OnButtonRun(), bbtk::WxGUITextEditor::Open(), bbtk::WxGUIOutputMessages::Print(), bbtk::WxGUITextEditorPage::Save(), bbtk::WxGUITextEditor::SaveCurrentPage(), bbtk::WxGUITextEditorPage::SaveFile(), bbtk::WxGUICommand::SendCommand(), bbtk::WxGUITextEditor::UpdateInfo(), bbtk::WxGUIBlackBoxInfo::UpdateInfo(), bbtk::WxStreamRedirector::writeString(), bbtk::WxGUIPackageBrowser2::WxGUIBlackBoxListUserOnSelected(), and bbtk::WxGUIScriptingInterface::WxGUIScriptingInterface().
00138 { 00139 wxString wx; 00140 const char* my_string=s.c_str(); 00141 wxMBConvUTF8 *wxconv= new wxMBConvUTF8(); 00142 wx=wxString(wxconv->cMB2WC(my_string),wxConvUTF8); 00143 delete wxconv; 00144 // test if conversion works of not. In case it fails convert from Ascii 00145 if(wx.length()==0) 00146 wx=wxString(wxString::FromAscii(s.c_str())); 00147 return wx; 00148 }
void bbtk::SubsBrackets | ( | std::string & | s | ) |
Definition at line 1052 of file bbtkBlackBox.cxx.
Referenced by bbtk::BlackBox::bbWriteDotFileBlackBox().
01053 { 01054 // std::cout << "BEFORE=["<<s<<"]"<<std::endl; 01055 std::string ss("<"); 01056 std::string::size_type pos = 0; 01057 pos = s.find(ss,0); 01058 std::string cr("["); 01059 while ( pos != std::string::npos ) 01060 { 01061 // std::cout << "*** find one "<<std::endl; 01062 s.replace(pos,1,cr.c_str(),1); 01063 pos = s.find(ss, pos); 01064 } 01065 ss = ">"; 01066 pos = 0; 01067 pos = s.find(ss,0); 01068 cr = "]"; 01069 while ( pos != std::string::npos ) 01070 { 01071 // std::cout << "*** find one "<<std::endl; 01072 s.replace(pos,1,cr.c_str(),1); 01073 pos = s.find(ss, pos); 01074 } 01075 ss = ","; 01076 pos = 0; 01077 pos = s.find(ss,0); 01078 cr = "-"; 01079 while ( pos != std::string::npos ) 01080 { 01081 // std::cout << "*** find one "<<std::endl; 01082 s.replace(pos,1,cr.c_str(),1); 01083 pos = s.find(ss, pos); 01084 } // std::cout << "AFTER=["<<s<<"]"<<std::endl; 01085 }
std::string bbtk::TypeName | ( | const T & | t | ) | [inline] |
Template method which returns the name of the type of a variable.
Definition at line 121 of file bbtkRTTI.h.
References BBTK_DEMANGLE_TYPE_NAME.
00122 { return BBTK_DEMANGLE_TYPE_NAME(typeid(t).name()); }
std::string bbtk::TypeName | ( | ) | [inline] |
Template method which returns the name of a type.
Definition at line 117 of file bbtkRTTI.h.
References BBTK_DEMANGLE_TYPE_NAME.
Referenced by bbtk::Executer::Get(), bbtk::ComplexBlackBoxOutputDescriptor::GetTypeName(), bbtk::ComplexBlackBoxInputDescriptor::GetTypeName(), HumanTypeName(), operator<<(), run_time_up_or_down_cast(), and bbtk::Executer::Set().
00118 { return BBTK_DEMANGLE_TYPE_NAME(typeid(T).name()); }
std::string bbtk::TypeName< std::type_info > | ( | const std::type_info & | t | ) | [inline] |
Specialisation of TypeName when the type passed is already a type_info : The user does not want to know the type of the type_info class but of the class whose type_info is passed !
std::string bbtk::wx2std | ( | const wxString & | s | ) | [inline] |
Conversion wxString to std::string.
Definition at line 153 of file bbtkWx.h.
Referenced by bbtk::Executer::DefineInput(), bbtk::WxGUIHtmlBrowser::GetCurrentPage(), bbtk::WxGUITextEditorPage::GetText(), bbtk::WxGUIPackageBrowser2::IsVisible(), bbtk::WxGUICommand::OnBtnGo(), bbtk::WxGUICommand::OnBtnInclude(), bbtk::WxGUICommand::OnCommandEnter(), bbtk::WxGUIHtmlBrowser::OnLinkClicked(), bbtk::WxGUIHtmlBrowser::OnLinkClicked2(), bbtk::WxGUIScriptingInterface::OnMenuPlugPackage(), bbtk::WxGUIScriptingInterface::OnMenuRegeneratePackageDoc(), bbtk::WxGUITextEditor::Open(), WxProcessCmdLine::Process(), bbtk::WxGUITextEditorPage::Save(), and bbtk::WxGUIScriptingInterface::SavePerspective().
00153 { 00154 std::string s2; 00155 if(s.wxString::IsAscii()) { 00156 s2=s.wxString::ToAscii(); 00157 } else { 00158 const wxWX2MBbuf tmp_buf = wxConvCurrent->cWX2MB(s); 00159 const char *tmp_str = (const char*) tmp_buf; 00160 s2=std::string(tmp_str, strlen(tmp_str)); 00161 } 00162 return s2; 00163 }