+ this->source = NULL;
+ this->header = NULL;
+}
+
+modelCDMBlackBox::modelCDMBlackBox(modelCDMIProjectTreeNode* parent, const std::string& path, const std::string& name, const int& level)
+{
+ std::cout << "creating black box: " + name + " in " + path + "\n";
+ this->parent = parent;
+ this->name = name;
+ this->path = path;
+ this->level = level;
+ this->type = wxDIR_DIRS;
+ this->source = NULL;
+ this->header = NULL;
+
+ std::string pathHeader = path + CDMUtilities::SLASH + "bb" + this->name + ".h";
+
+ std::ifstream confFile;
+ confFile.open((pathHeader).c_str());
+ std::string word;
+ while(confFile.is_open() && !confFile.eof())
+ {
+ //get BBTK's
+ std::getline(confFile,word,'(');
+ std::vector<std::string> wordBits;
+ CDMUtilities::splitter::split(wordBits,word," \n",CDMUtilities::splitter::no_empties);
+
+ if(wordBits[wordBits.size()-1] == "BBTK_NAME")
+ {
+ std::getline(confFile,word,'"');
+ std::getline(confFile,word,'"');
+ this->nameBlackBox = word;
+ }
+ else if(wordBits[wordBits.size()-1] == "BBTK_AUTHOR")
+ {
+ std::getline(confFile,word,'"');
+ std::getline(confFile,word,'"');
+ this->authors = word;
+ }
+ else if(wordBits[wordBits.size()-1] == "BBTK_DESCRIPTION")
+ {
+ std::getline(confFile,word,'"');
+ std::getline(confFile,word,'"');
+ this->description = word;
+ }
+ else if(wordBits[wordBits.size()-1] == "BBTK_CATEGORY")
+ {
+ std::getline(confFile,word,'"');
+ std::getline(confFile,word,'"');
+ this->categories = word;
+ if (this->categories == "")
+ this->categories = "empty";
+ }
+ }
+ confFile.close();
+