Changeset 114 for XMLIO_V2/dev/dev_rv/src/XMLIO/c_interface.cpp
- Timestamp:
- 06/23/10 10:29:45 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
XMLIO_V2/dev/dev_rv/src/XMLIO/c_interface.cpp
r112 r114 1 /*using namespace XMLIOSERVER; 1 #include "xmlio.hpp" 2 3 using namespace XMLIOSERVER; 2 4 using namespace XMLIOSERVER::XML; 3 5 using namespace std; 4 6 5 extern "C" 6 { // Début du code C 7 8 typedef void *XMLIOhandle; 9 10 // VIDE TEMPORAIREMENT 11 12 }*/ 7 extern "C" void main_c_(void) ; 13 8 9 void main_c_ (void) 10 { 11 try 12 { 13 string file("/local/XMLIOSERVER_DEV/dev_rv/test/iodef_test.xml"); 14 //string file("/local/XMLIOSERVER_DEV/dev_rv/iodef_test.xml"); 15 16 ifstream istr( file.c_str() , ifstream::in ); 17 18 // 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, Context::GetRootName()); 20 // On parse le fichier xml noeud par noeud (ie on construit dynamiquement notre arbre d'objets). 21 XMLParser::Parse(node); 22 23 // On résoud les héritages descendants ainsi que les héritages par référence. 24 Context::ResolveInheritance(); 25 26 // On écrit l'arborescence résultante du traitement sur la sortie. 27 Context::ShowTree(std::clog); 28 29 } 30 catch(const Exception &exc) 31 { // Pour tout type d'exceptions, on note les informations sur la sortie paramétrée. 32 ERROR(exc.displayText()); 33 // On retourne le code d'erreur en fin d'application pour traitements éventuels. 34 // return (exc.code()); 35 } 36 37 // return (0); 38 }
Note: See TracChangeset
for help on using the changeset viewer.