Changeset 108 for XMLIO_V2


Ignore:
Timestamp:
06/18/10 14:33:19 (14 years ago)
Author:
hozdoba
Message:

Début de prise en charge des références (sans contrÎle ni transmission d'attribut pour le moment).

Location:
XMLIO_V2/dev/dev_rv/src/XMLIO
Files:
13 edited

Legend:

Unmodified
Added
Removed
  • XMLIO_V2/dev/dev_rv/src/XMLIO/attribut.hpp

    r104 r108  
    1212   class IStringStream_alt 
    1313   { 
    14       public :  
     14      public : 
    1515         IStringStream_alt(const std::string& str) : iss(str) 
    1616         { /* Ne rien faire de plus */} 
    17           
     17 
    1818         istream& operator>> (std::string& s) {s.assign(this->iss.str()); return (this->iss);} 
    1919         istream& operator>> (int& s) { return (iss>>s); } 
     
    2424            return (this->iss); 
    2525         } 
    26           
    27       private :  
     26 
     27      private : 
    2828         istringstream iss; 
    29           
     29 
    3030   }; // class IStringStream_alt 
    3131 
     
    3535   { 
    3636      public : 
    37       
     37 
    3838         bool hasValue ; 
    3939         Ctype value ; 
    40           
    41          virtual bool _hasValue() {return hasValue;} 
    4240 
    43          virtual const char * getName(void) const = 0 ; 
    44        
     41         virtual bool _hasValue() const { return hasValue; } 
     42 
    4543         Attribut(void) : hasValue(false) {} ; 
    4644         Attribut(const Ctype& value_) : hasValue(true), value(value_) {} ; 
    47           
    48          Attribut(const Attribut& attr) : hasValue(attr.hasValue)  
     45 
     46         Attribut(const Attribut& attr) : hasValue(attr.hasValue) 
    4947         {  if (hasValue) value=attr.value ; } 
    5048 
    5149         Attribut& operator = (const Attribut & attr) 
    52          {  
     50         { 
    5351            hasValue=attr.hasValue ; 
    5452            if (hasValue) value=attr.value ; 
    55             return *this ;  
     53            return *this ; 
    5654         } 
    57       
     55 
    5856         virtual const char * getType(void) const = 0; 
    59       
    60          virtual void setFromString(const std::string str)  
    61          {     
     57 
     58         virtual void setFromString(const std::string str) 
     59         { 
    6260            IStringStream_alt iss(str); Ctype val; 
    6361            iss >> val; 
    6462            this->setValue(val); 
    65          }    
     63         } 
    6664 
    67          operator Ctype() 
     65         operator Ctype() const 
    6866         { 
    69             if (!hasValue) 
    70             { 
    71                ostringstream oss; 
    72                oss << "CAttribut& CAttribut<Ctype>::operator Ctype , access to undefined value of attribut <<" << this->getName() <<">>"; 
    73                                                                            
    74                throw XMLIOUndefinedValueException(oss.str()); 
    75             } 
     67            if (!hasValue) throw XMLIOUndefinedValueException("L'attribut \"" + this->getName() + "\" est invalide !"); 
    7668            return value ; 
    7769         } 
    78           
     70 
    7971         virtual void assignValue(const BaseAttribut* _ba) 
    8072         { value = ((Attribut*)_ba) -> value; hasValue = true; } 
     
    8577         virtual void setValue(const Ctype & value_) 
    8678         { hasValue=true ; value=value_ ; } 
    87           
     79 
    8880         virtual void getValue(Ctype & value_) const 
    8981         { 
    90             if (!hasValue) 
    91             { 
    92                ostringstream oss; 
    93                oss << "CAttribut& CAttribut<Ctype>::operator Ctype , access to undefined value of attribut <<" << this->getName() <<">>"; 
    94                                                                            
    95                throw XMLIOUndefinedValueException(oss.str()); 
    96             } 
     82            if (!hasValue) throw XMLIOUndefinedValueException("L'attribut \"" + this->getName() + "\" est invalide !"); 
    9783            value_=value ; 
    9884         } 
    9985 
    100    }; // class Attribut  
     86   }; // class Attribut 
    10187}; // namespace XMLIOSERVER 
    102    
     88 
    10389#endif //__ATTRIBUT__ 
  • XMLIO_V2/dev/dev_rv/src/XMLIO/attribut_registrar.hpp

    r107 r108  
    5252         void setSAttribut(const string& att_name, const std::string& value) 
    5353         { 
    54             //std::cout << "Attribut :" <<  att_name<< ", " << value<< std::endl; 
    55  
    56             if (hasAttribut(att_name)) 
    57             { getAttribut(att_name)->setFromString(value) ; } 
    58             else 
    59             { 
    60                ostringstream oss; 
    61                oss << "CAttributRegistrar::setAttribut<ValueType>, could not find <<" << att_name <<">> attribut in registred list" <<">>"; 
    62                throw XMLIOUndefinedValueException(oss.str()); 
    63             } 
     54            if (hasAttribut(att_name)) getAttribut(att_name)->setFromString(value); 
     55            else throw XMLIOUndefinedValueException("Impossible de trouver l'attribut nommé \"" + att_name +"\" dans la liste des attributs enregistrés !"); 
    6456         } 
    6557 
  • XMLIO_V2/dev/dev_rv/src/XMLIO/base_attribut.hpp

    r104 r108  
    1313   { 
    1414      public: 
    15       
    16          virtual const char * getName(void) const = 0  ;         
     15 
     16         virtual string getName(void) const = 0  ; 
    1717         virtual ostream & print(ostream& o) const = 0  ; 
    18       
     18 
    1919         friend ostream& operator <<(ostream& o,const BaseAttribut& Attr) 
    2020         {return Attr.print(o) ; } 
    21           
     21 
    2222         virtual void assignValue(const BaseAttribut*) = 0; 
    23       
    24          virtual const char * getId(void) {return getName();} ; 
     23 
     24         virtual string getId(void) const {return getName();} ; 
    2525         bool hasId(void){return (true);} 
    2626 
    2727         virtual void setFromString(const std::string str) = 0; 
    28       
     28 
    2929#define  SETTER_AND_GETTER(TYPE) \ 
    3030         virtual void setValue(const TYPE & value)          { error_set() ; }\ 
     
    3636         virtual void getValue(Array<TYPE,2>& value) const  { error_get() ; }\ 
    3737         virtual void getValue(Array<TYPE,3>& value) const  { error_get() ; } 
    38           
     38 
    3939         SETTER_AND_GETTER(int) 
    4040         SETTER_AND_GETTER(bool) 
     
    4242         SETTER_AND_GETTER(char) 
    4343         SETTER_AND_GETTER(string) 
    44        
     44 
    4545#undef SETTER_AND_GETTER 
    4646 
    47           
    48          virtual bool _hasValue() = 0; 
     47 
     48         virtual bool _hasValue() const = 0; 
    4949 
    5050         static void error_set(void) 
     
    5353         static void error_get(void) 
    5454         { throw XMLIOIncompatibleTypeException("BaseAttribut::set<type> >Getting value type is incompatible with attribut type"); } 
    55       
     55 
    5656   }; //class BaseAttribut 
    5757} // namespace XMLIOSERVER 
    5858 
    5959#endif //__BASE_ATTRIBUT__ 
    60    
     60 
  • XMLIO_V2/dev/dev_rv/src/XMLIO/context.hpp

    r107 r108  
    1616         static void ShowTree(ostream& os = std::clog) 
    1717         { 
    18             clog << "<?xml version=\"1.0\"?>" << std::endl; 
    19             clog <<  "<simulation>" << std::endl; 
     18            clog << NIndent << "<?xml version=\"1.0\"?>" << std::endl; 
     19            clog << NIndent << "<"<< Context::GetRootName() << ">" << std::endl; 
    2020            HashMap<string, StrHashMap<Context> > &AllListContext = Context::GetAllListObject(); 
    2121            for (HashMap<string, StrHashMap<Context> >::Iterator it = AllListContext.begin(); it != AllListContext.end(); it++) 
    2222               // On sort chacun des contextes successivement. 
    23                clog << *((*it).second)[(*it).first] << std::endl; 
    24             clog << "</simulation>" << std::endl  ; 
     23            { Context::SetCurrentContext((*it).first); clog << *((*it).second)[(*it).first] << std::endl; } 
     24            clog << NIndent << "</" << Context::GetRootName() << ">" << std::endl  ; 
    2525         } 
    2626 
     
    3636            HashMap<string, StrHashMap<Context> > &AllListContext = Context::GetAllListObject(); 
    3737            for (HashMap<string, StrHashMap<Context> >::Iterator it = AllListContext.begin(); it != AllListContext.end(); it++) 
    38                // Résolution des héritages des descendands (càd des héritages de groupes) pour chacun des contextes. 
     38            { 
     39               // Résolution des héritages descendants (càd des héritages de groupes) pour chacun des contextes. 
     40               Context::SetCurrentContext((*it).first); 
    3941               ((*it).second)[(*it).first]->resolveDescInheritance(); 
     42 
     43               // Résolution des héritages par référence au niveau des fichiers 
     44               const std::vector<CFile*>& allFiles = CFile::GetCurrentListObject().getVector(); 
     45               for (unsigned int i = 0; i < allFiles.size(); i++) allFiles[i]->resolveFieldRefInheritance(); 
     46            } 
    4047         } 
    4148 
     
    113120 
    114121         static string GetName(void) {return ("context"); } 
     122         static string GetRootName(void) {return ("simulation"); } 
    115123 
    116124         virtual bool hasChild(void) const 
  • XMLIO_V2/dev/dev_rv/src/XMLIO/declare_attribut.hpp

    r98 r108  
    88   {                                                  \ 
    99      public:                                         \ 
    10          const char * getName(void) const { return #att_name ;}                     \ 
     10         virtual string getName(void) const { return #att_name ;}                   \ 
    1111         virtual const char * getType(void) const { return #att_type ;}             \ 
    1212         attr_##att_name(void) : Attribut<att_type>() {}                            \ 
  • XMLIO_V2/dev/dev_rv/src/XMLIO/field.hpp

    r107 r108  
    1717 
    1818         static string GetName(void) {return ("field"); } 
     19 
     20         virtual CField* getReference(void) const 
     21         { 
     22            if(!field_ref._hasValue()) return (NULL); 
     23            string refname = field_ref; 
     24            if (!CField::HasObject(refname)) 
     25            { WARNING("Référence invalide sur l'objet "+GetName()+" nommé \""+refname+"\""); return (NULL);} 
     26 
     27            return (&CField::GetObject(field_ref)); 
     28         } 
    1929 
    2030         void parse (XMLNode& _node) 
  • XMLIO_V2/dev/dev_rv/src/XMLIO/file.hpp

    r107 r108  
    3636         } 
    3737 
     38         void getAllFields(std::vector<CField*>& _allF) const {  if (vfieldGroup!=NULL) vfieldGroup->getAllChildren(_allF); } 
    3839         virtual bool hasChild(void) const { return (vfieldGroup != NULL); } 
    3940         virtual void printChild(ostream& out) const { out << *vfieldGroup << std::endl; } 
     41         /*{ // Sortie sans affichage des groupes. 
     42            std::vector<CField*> allF; getAllFields(allF); 
     43            for (unsigned int i = 0; i < allF.size(); i++) 
     44               out << *(allF[i]) << std::endl; 
     45         }*/ 
    4046         virtual void resolveDescInheritance(const AttributRegistrar* _parent = 0) 
    4147         { addAttributes(*_parent); if(vfieldGroup != NULL) vfieldGroup->resolveDescInheritance(); } 
     48 
     49         void resolveFieldRefInheritance(void) 
     50         { 
     51            std::vector<CField*> allF; getAllFields(allF); 
     52            for (unsigned int i = 0; i < allF.size(); i++) allF[i]->resolveRefInheritance(); 
     53         } 
    4254 
    4355         FieldGroup* getVirtualFieldGroup(void) { return (vfieldGroup); } 
  • XMLIO_V2/dev/dev_rv/src/XMLIO/main_cpp.cpp

    r107 r108  
    1212   { 
    1313      string file("/local/XMLIOSERVER_DEV/dev_rv/test/iodef_test.xml"); 
     14      //string file("/local/XMLIOSERVER_DEV/dev_rv/iodef_test.xml"); 
    1415 
    15       //string file("/local/XMLIOSERVER_DEV/dev_rv/iodef_test.xml"); 
    1616      ifstream istr( file.c_str() , ifstream::in ); 
    1717 
    1818      // On commence la lecture du flux de donnée xml qui doit posséder pour racine un unique noeud nommé "simulation". 
    19       XMLNode node = XMLNode::CreateNode(istr, "simulation"); 
     19      XMLNode node = XMLNode::CreateNode(istr, Context::GetRootName()); 
    2020      // On parse le fichier xml noeud par noeud (ie on construit dynamiquement notre arbre d'objets). 
    2121      XMLParser::Parse(node); 
     
    2626      // On poursuit le traitement ... 
    2727 
    28       // On écrit l'arborescence resultante du traitement sur la sortie. 
     28      // On écrit l'arborescence résultante du traitement sur la sortie. 
    2929      Context::ShowTree(std::clog); 
    3030 
  • XMLIO_V2/dev/dev_rv/src/XMLIO/xmlio_group_template.hpp

    r107 r108  
    5151            groupList.addObject(&obj); 
    5252 
    53             return (GroupTemplate<T, U>::GetObject(_id)); 
     53            return (obj); 
    5454         } 
    5555 
     
    8989 
    9090         const StrHashMap<T*>& getCurrentListChild(void) { return (childList); } 
     91         const vector<T*>& getCurrentVectorChild(void) { return (childList.getVector()); } 
    9192 
    9293         size_t getNbChild() const {return (childList.getVectorSize()); } 
     94 
     95         void getAllChildren(std::vector<T*>& _allc ) 
     96         { 
     97            const vector<GroupTemplate<T, U>*>& groupvect = groupList.getVector(); 
     98            _allc.insert (_allc.end(), getCurrentVectorChild().begin(), getCurrentVectorChild().end()); 
     99 
     100            for(unsigned int i = 0; i < groupvect.size() ; i++) 
     101               groupvect[i] -> getAllChildren(_allc); 
     102         } 
    93103 
    94104         virtual ~GroupTemplate() 
     
    108118            {// Si l'identifiant est défini. 
    109119               if (V::HasObject(attributes["id"])) 
    110                   WARNING("Dans le context actuel, une instance de type "+V::GetName()+" nommée "+attributes["id"]+" existe déjà, le second fera référence au premier par défaut !"); // TODO TODO 
     120                  WARNING("Dans le context actuel, une instance de type "+V::GetName()+" nommée \""+attributes["id"]+"\" existe déjà, le second fera référence au premier par défaut !"); // TODO TODO 
    111121               instance_ptr = (V*)(&createGroup(attributes["id"])); 
    112122               instance_ptr->parse(_node); 
     
    126136            {// Si l'identifiant est défini. 
    127137               if (V::HasObject(attributes["id"])) 
    128                   WARNING("Dans le context actuel, une instance de type "+V::GetName()+" nommée "+attributes["id"]+" existe déjà, le second fera référence au premier par défaut !"); // TODO TODO 
     138                  WARNING("Dans le context actuel, une instance de type "+V::GetName()+" nommée \""+attributes["id"]+"\" existe déjà, le second fera référence au premier par défaut !"); // TODO TODO 
    129139               instance_ptr = (V*)(&createChild(attributes["id"])); 
    130140               instance_ptr->parse(_node); 
  • XMLIO_V2/dev/dev_rv/src/XMLIO/xmlio_logger.hpp

    r106 r108  
    11#ifndef __XMLIO_LOGGER__ 
    2 #define __XMLIO_LOGGER__  
     2#define __XMLIO_LOGGER__ 
    33 
    44// Entête Poco logging 
     
    1212#include <Poco/AutoPtr.h> 
    1313 
     14#include <csignal> 
     15 
     16#ifdef __GNUC__ 
     17#include <execinfo.h> 
     18#include <cxxabi.h> 
     19#endif // __GNUC__ 
    1420 
    1521// Classes utilisées issues de Poco 
     
    2834   { 
    2935      public : 
    30        
     36 
    3137         ILogger(const string& _fileLogName, bool _withConsole = true) 
    3238         { 
    3339            // Perte mémoire faible ici (/ still reachable: 84 bytes in 2 blocks /) 
    34     
     40 
    3541            // TODO Créer une sortie fichier. 
    3642            AutoPtr<PatternFormatter> pf = new PatternFormatter("[%Y-%m-%d %H:%M:%S] %t"); 
     
    3844            AutoPtr<FormattingChannel> pFCConsole = new FormattingChannel(pf); 
    3945            pFCConsole->setChannel(cc); 
    40             pFCConsole->open();             
     46            pFCConsole->open(); 
    4147            Logger::create("ConsoleLogger", pFCConsole, Message::PRIO_INFORMATION); 
     48 
     49            signal(SIGSEGV, SigHandler); 
    4250         } 
    4351 
    44          static Logger & GetConsoleLogger(void) {return (Logger::get("ConsoleLogger"));}    
    45           
    46          ~ILogger(void)  
    47          { /* Ne rien faire de plus */ }    
    48                 
     52 
     53         static void ShowBTrace(std::ostream& out = std::clog) 
     54         { 
     55#ifdef __GNUC__ 
     56            int status = 0; 
     57            string value; 
     58            void *stack_addrs[20] = {NULL}; 
     59            size_t stack_depth = backtrace(stack_addrs, 20); 
     60            char **stack_strings = backtrace_symbols(stack_addrs, stack_depth); 
     61 
     62            out << "Trace : " << std::endl; 
     63            for (size_t i = 2, j = 0; i < stack_depth; i++) 
     64            { 
     65               value.assign(stack_strings[i]); 
     66               size_t bpos = value.find ('('), epos = value.find ('+'); 
     67               if ((bpos != string::npos) and (epos != string::npos)) 
     68               { 
     69                  char* demangled_name = abi::__cxa_demangle(value.substr(bpos+1, epos-bpos-1).c_str(), 0, 0, &status); 
     70                  if (status == 0) out << "   "  << ++j << " -> "  << (demangled_name) << std::endl; 
     71                  else out << "   "  << ++j << " -> "  << value.substr(bpos+1, epos-bpos-1) << std::endl; 
     72                  free(demangled_name); 
     73               } 
     74            } 
     75 
     76            free(stack_strings); 
     77#endif // __GNUC__ 
     78         } 
     79 
     80         static void SigHandler(int _sigValue) 
     81         { 
     82            std::cerr << "============= Erreur =============" << std::endl; 
     83            std::cerr << "Signal " << _sigValue << " reçu !" << std::endl; 
     84            ShowBTrace(std::cerr); 
     85            std::cerr << "==================================" << std::endl; 
     86            exit(EXIT_FAILURE); 
     87         } 
     88 
     89 
     90         static Logger & GetConsoleLogger(void) {return (Logger::get("ConsoleLogger"));} 
     91 
     92         ~ILogger(void) 
     93         { /* Ne rien faire de plus */ } 
     94 
    4995   }; // class XMLIOLogger 
    50     
     96 
    5197   // Initialisation de la classe de Logging 
    5298   static ILogger LOGGER("xmlio.log"); 
    5399 
    54 ///////////////////////////////////////////////////////////////////// 
    55 static unsigned int Indent; 
     100   ///////////////////////////////////////////////////////////////////// 
     101   static unsigned int Indent = 0; 
     102   static const char*  Increm = "   "; 
    56103 
    57 std::ostream& NIndent(std::ostream& out) 
    58 { for(unsigned int i = 0; i < Indent; i++) out << "  "; return(out); } 
     104   std::ostream& NIndent(std::ostream& out) 
     105   { 
     106      static unsigned int LineNB = 1; 
     107      out<< LineNB++ << ". "; 
     108      for(unsigned int i = 0;i < Indent; i++) out << Increm; 
     109      return(out); 
     110   } 
    59111 
    60 std::ostream& IncIndent(std::ostream& out) { Indent++; return (NIndent(out)); } 
    61 std::ostream& DecEndl(std::ostream& out) { Indent--; return (NIndent(out)); } 
    62 ///////////////////////////////////////////////////////////////////// 
     112   std::ostream& IncIndent(std::ostream& out) { Indent++; return (NIndent(out)); } 
     113   std::ostream& DecEndl(std::ostream& out) { Indent--; return (out); } 
     114   ///////////////////////////////////////////////////////////////////// 
    63115 
    64 /************* POUR MEMOIRE ********************** 
    65 #include <stdio.h>  
    66 #include <execinfo.h>  
    67 #include <signal.h>  
    68 #include <stdlib.h>  
    69   
    70 void handler(int sig) {  
    71   void *array[10];  
    72   size_t size;  
    73   // get void*'s for all entries on the stack  
    74   size = backtrace(array, 10);  
    75   // print out all the frames to stderr  
    76   fprintf(stderr, "Error: signal %d:\n", sig);  
    77   backtrace_symbols_fd(array, size, 2);  
    78   exit(1);  
    79 }  
    80 void baz() {  
    81  int *foo = (int*)-1; // make a bad pointer  
    82   printf("%d\n", *foo);       // causes segfault  
    83 }  
    84 void bar() { baz(); }  
    85 void foo() { bar(); }  
    86   
    87 int main(int argc, char **argv) {  
    88   signal(SIGSEGV, handler);   // install our handler  
    89   foo(); // this will call foo, bar, and baz.  baz segfaults.  
    90 }  
    91   
    92  ***************************************************************/ 
    93     
    94116}; // namespace XMLIOSERVER 
    95117 
     
    99121// A compléter. 
    100122 
    101 #endif // __XMLIO_LOGGER__   
     123#endif // __XMLIO_LOGGER__ 
  • XMLIO_V2/dev/dev_rv/src/XMLIO/xmlio_object_template.hpp

    r107 r108  
    2222      public : 
    2323 
    24  
    2524         friend ostream& operator<< (ostream& out, const T& c) 
    2625         { 
    2726            const AttributRegistrar &ar = c; 
     27 
     28            if (c.baseObject != NULL) 
     29               out <<  IncIndent << "<-- Reference resolved for the following "+ T::GetName() +" : \"" << c.baseObject->getId() << "\" -->" << DecEndl << std::endl; 
     30 
    2831            if (c.hasChild()) 
    2932            { 
     
    3942         string getName(void) const {return (T::GetName()); } 
    4043 
     44         virtual T* getReference(void) const { return (NULL); } 
     45 
    4146         virtual bool hasChild(void) const { return (false); } 
    4247         virtual void printChild(ostream& out) const { /* Ne rien faire de plus */ } 
     48 
    4349         virtual void resolveDescInheritance(const AttributRegistrar* _parent = 0) { addAttributes(*_parent); } 
     50         virtual void resolveRefInheritance(void) 
     51         { 
     52            std::vector<T*> allRef; 
     53            T* refer = (T*)this; 
     54            // On remonte le fil des héritages par référence (Boucle infinie). 
     55            while((refer = refer->getReference()) != NULL) 
     56               allRef.insert(allRef.begin(), baseObject = refer); 
     57 
     58            // Gestion des attributs ici. 
     59         } 
    4460 
    4561         static T& CreateObject(const string _id) throw (XMLIOUndefinedValueException) 
     
    8399      protected : 
    84100 
    85          ObjectTemplate(void) : AbstractObject() 
     101         ObjectTemplate(void) : AbstractObject(), baseObject(NULL) 
    86102         {/* Ne rien faire de plus */} 
    87          ObjectTemplate(const string& _id) : AbstractObject(_id) 
     103         ObjectTemplate(const string& _id) : AbstractObject(_id), baseObject(NULL) 
    88104         {/* Ne rien faire de plus */} 
    89105 
     
    100116            { 
    101117               if (V::HasObject(did)) 
    102                   WARNING("Le noeud nommé "+ did +" existe déjà pour les instances de type "+V::GetName()+", le dernier défini complétera le premier dans le context actuel!"); 
     118                  WARNING("Le noeud nommé \""+ did +"\" existe déjà pour les instances de type "+V::GetName()+", le dernier défini complétera le premier dans le context actuel!"); 
    103119               instance_ptr = (V*)&V::CreateObject(did); 
    104120               instance_ptr->parse(_node, parseAttr); 
     
    108124 
    109125      private : 
     126         T* baseObject; 
    110127 
    111128         static string CurrContext; 
  • XMLIO_V2/dev/dev_rv/src/XMLIO/xmlio_xml_node.hpp

    r107 r108  
    5454            { /* Ne rien faire de plus */} 
    5555 
    56             static XMLNode CreateNode(istream& _istr, const string& _rootName = string("simulation")) 
     56            static XMLNode CreateNode(istream& _istr, const string& _rootName) 
    5757            { 
    5858               XMLNode node(_rootName); 
  • XMLIO_V2/dev/dev_rv/src/XMLIO/xmlio_xml_parser.hpp

    r107 r108  
    3131                  { WARNING("Le context ne sera pas traité car il n'est pas identifié !"); continue; } 
    3232 
    33                   if( Context::HasObject(attributes["id"])) 
     33                  if( Context::GetAllListObject().find(attributes["id"]) != Context::GetAllListObject().end()) 
    3434                  { WARNING("Le context ne sera pas traité car il existe déjà un autre context possédant le même nom !"); continue; } 
    3535 
Note: See TracChangeset for help on using the changeset viewer.