Changeset 216


Ignore:
Timestamp:
06/15/11 14:03:15 (13 years ago)
Author:
hozdoba
Message:
 
Location:
XMLIO_V2/dev/dev_rv
Files:
3 added
10 edited

Legend:

Unmodified
Added
Removed
  • XMLIO_V2/dev/dev_rv/Doxyfile

    r215 r216  
    5252# where doxygen was started. If left blank the current directory will be used. 
    5353 
    54 OUTPUT_DIRECTORY       = /home/herve/dev/dev_rv/wk/doc 
     54OUTPUT_DIRECTORY       = wk/doc 
    5555 
    5656# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create  
     
    620620# with spaces. 
    621621 
    622 INPUT                  = /home/herve/dev/dev_rv/src4/xmlio 
     622INPUT                  = src4/xmlio 
    623623 
    624624# This tag can be used to specify the character encoding of the source files  
  • XMLIO_V2/dev/dev_rv/Makefile.wk

    r215 r216  
    1616GUI       = no 
    1717NPROC     = 6 
    18 VERSION   = 4 
     18#VERSION   = 4 
    1919CSUITE    = intel 
    2020PFORME    = fedora-wk 
     
    267267 
    268268INCLUDE += -I $(INC_PATH) 
    269 DEFINE  += -D XIOS_LIBRARY 
     269DEFINE  += -D __XIOS_LIBRARY 
    270270 
    271271LIBS      += -lstdc++ 
     
    278278NODEPS   = clean clean-all dir-tree 
    279279 
    280 FFLAGS  += -D XIOS_LIBRARY 
     280FFLAGS  += -D __XIOS_LIBRARY 
    281281CFLAGS  += $(DEFINE) $(INCLUDE) 
    282282LDFLAGS += $(LIBS_PATH) $(LIBS) 
     
    390390 
    391391ifeq ($(VERSION), 4) 
    392         ELEMS_CPP = object exception 
     392        ELEMS_CPP = object exception xml_node xml_parser 
    393393endif 
    394394 
     
    544544 
    545545$(DEP_PATH)/%.d: %.cpp $(DEP_PATH)/mark 
    546         $(CDEP) $(DEFLAGS) -D XIOS_NO_EXTERN -MT $(OBJ_PATH)/$(patsubst %.d,%.o,$(@F)) -MM -MF $@ $< 
     546        $(CDEP) $(DEFLAGS) -D __XIOS_NO_EXTERN -MT $(OBJ_PATH)/$(patsubst %.d,%.o,$(@F)) -MM -MF $@ $< 
    547547 
    548548# Entêtes cpp 
  • XMLIO_V2/dev/dev_rv/src4/xmlio/exception.cpp

    r215 r216  
    1111 */ 
    1212 
     13#ifndef __XIOS_NO_EXTERN 
     14 
     15// Boost headers 
     16#include <boost/cast.hpp> 
     17 
     18#endif // __XIOS_NO_EXTERN 
     19 
    1320// XMLIOServer headers 
    1421#include "xmlioserver_spl.hpp" 
    1522#include "exception.hpp" 
    16  
    17 // Boost headers 
    18 #include <boost/cast.hpp> 
    1923 
    2024// /////////////////////////////// Définitions ////////////////////////////// // 
  • XMLIO_V2/dev/dev_rv/src4/xmlio/exception.hpp

    r215 r216  
    66#define __EXCEPTION_HPP__ 
    77 
     8#ifndef __XIOS_NO_EXTERN 
     9 
     10// C++ standard headers 
     11#  include <sstream> 
     12 
     13#endif // __XIOS_NO_EXTERN 
     14 
    815// XMLIOServer headers 
    916#include "object.hpp" 
    1017 
    11 // C++ standard headers 
    12 #include <sstream> 
    1318 
    1419/** 
  • XMLIO_V2/dev/dev_rv/src4/xmlio/object.cpp

    r215 r216  
    1111 */ 
    1212 
     13#ifndef __XIOS_NO_EXTERN 
     14 
     15// Boost headers 
     16#include <boost/none.hpp> 
     17 
     18#endif // __XIOS_NO_EXTERN 
     19 
    1320// XMLIOServer headers 
    1421#include "xmlioserver_spl.hpp" 
    1522#include "object.hpp" 
    16  
    17 // Boost headers 
    18 #include <boost/none.hpp> 
    1923 
    2024// /////////////////////////////// Définitions ////////////////////////////// // 
     
    3741   { /* Ne rien faire de plus */ } 
    3842 
    39    // ------------------------------- Destructeur ----------------------------- 
     43   // ------------------------------- Destructeur ------------------------------ 
    4044 
    4145   //- Destructeur de l'objet. 
     
    4347   { /* Ne rien faire de plus */ } 
    4448 
    45    // ------------------------------- Accesseurs ------------------------------ 
     49   // ------------------------------- Accesseurs ------------------------------- 
    4650 
    4751   //- Retourne l'identifiant de l'objet. 
     
    5458   } 
    5559 
    56    // --------------------------- Tests sur l'objet --------------------------- 
     60   // --------------------------- Tests sur l'objet ---------------------------- 
    5761 
    5862   //- Indique si l'objet est identifié. 
     
    6266   } 
    6367 
    64    // ------------------------------- Mutateurs ------------------------------- 
     68   // ------------------------------- Mutateurs -------------------------------- 
    6569 
    6670   //- Supprime l'identifiant de l'objet, rendant ce dernier anonyme. 
     
    7680   } 
    7781 
    78    // ----------------------- Opérateurs de comparaison ---------------------- 
     82   // ----------------------- Opérateurs de comparaison ------------------------ 
    7983 
    8084   //- Indique si deux objets sont identiques. 
     
    9195   } 
    9296 
    93    // --------------------------- Flux de sortie ---------------------------- 
     97   // --------------------------- Flux de sortie ------------------------------- 
    9498 
    9599   //- Opérateur de flux de sortie ascii.  
  • XMLIO_V2/dev/dev_rv/src4/xmlio/object.hpp

    r215 r216  
    1414 */ 
    1515 
     16#ifndef __XIOS_NO_EXTERN 
     17 
    1618// C++ standard headers 
    1719#include <string> 
     
    2022// Boost headers 
    2123#include <boost/optional.hpp> 
     24 
     25#endif // __XIOS_NO_EXTERN 
    2226 
    2327// ////////////////////////////// Déclarations ///////////////////////////// // 
  • XMLIO_V2/dev/dev_rv/src4/xmlio/xml/xml_node.cpp

    r215 r216  
    1919namespace xml { 
    2020 
     21   // ------------------------ Propriété statique privée ----------------------- 
     22    
     23   // Nom de l'élément racine du document xml. 
     24   std::string CXMLNode::RootName("simulation"); 
    2125 
     26   // ------------------------------ Constructeurs ----------------------------- 
     27 
     28   // Constructeur d'un noeud xml. 
     29   CXMLNode::CXMLNode(rapidxml::xml_node<char> * const _root) 
     30      : node(_root) 
     31   { /* Ne rien faire de plus */ } 
     32       
     33   // ------------------------------- Destructeur ------------------------------ 
     34 
     35   // Destructeur de l'objet. 
     36   CXMLNode::~CXMLNode(void) 
     37   { /* Ne rien faire de plus */ } 
     38 
     39   // ------------------------------- Accesseurs ------------------------------- 
     40 
     41   // Retourne les valeurs d'attributs de l'élément courant (pointé dans le document xml). 
     42   std::map <std::string, std::string> CXMLNode::getAttributes(void) const 
     43   { 
     44      std::map <std::string, std::string> attributes; 
     45      rapidxml::xml_attribute<char> * currentAttr = NULL; 
     46 
     47      if ((currentAttr = this->node->first_attribute()) != NULL) 
     48      { 
     49         do  
     50         { 
     51            attributes.insert(std::pair<std::string, std::string> 
     52                             (std::string(currentAttr->name()), 
     53                              std::string(currentAttr->value()))); 
     54         } while ((currentAttr = currentAttr->next_attribute()) != NULL); 
     55      } 
     56 
     57      return (attributes) ; 
     58   } 
     59    
     60   // Retourne le nom de l'élément courant (pointé dans le document xml). 
     61   std::string CXMLNode::getElementName(void) const 
     62   {  
     63         return (this->node->name());  
     64   } 
     65    
     66   // ------------------------------- Mutateurs -------------------------------- 
     67 
     68   // Déplace le pointeur du noeud actuel vers le suivant si possible. 
     69   bool CXMLNode::goToNextElement(void) 
     70   { 
     71      bool retvalue = false; 
     72      for(rapidxml::xml_node<char> * nextElement = this->node->next_sibling(); 
     73                                   ; nextElement = this->node->next_sibling()) 
     74      { 
     75         if (nextElement == NULL) break; 
     76         else if (nextElement->type() == rapidxml::node_element) 
     77         {  
     78            node = nextElement; 
     79            return (!retvalue); 
     80         } 
     81      } 
     82      return (retvalue); 
     83   } 
     84 
     85   // Déplace le pointeur du noeud actuel vers son premier enfant si possible. 
     86   bool CXMLNode::goToChildElement(void) 
     87   { 
     88      bool retvalue = false; 
     89      rapidxml::xml_node<char> * nextElement = this->node->first_node(); 
     90      if (nextElement != NULL) 
     91      { 
     92         for(;;nextElement = this->node->next_sibling()) 
     93         { 
     94            if (nextElement == NULL) break; 
     95            else if (nextElement->type() == rapidxml::node_element) 
     96            {  
     97               node = nextElement;  
     98               return (!retvalue);  
     99            } 
     100         } 
     101      } 
     102      return (retvalue); 
     103   } 
     104 
     105   // Déplace le pointeur du noeud actuel vers son parent si possible. 
     106   bool CXMLNode::goToParentElement(void) 
     107   { 
     108      bool retvalue = false; 
     109      if (!(this->getElementName().compare(CXMLNode::RootName))) 
     110         return (retvalue); 
     111      node = node->parent(); 
     112      return (!retvalue); 
     113   } 
     114    
     115   // -------------------------- Accesseurs statiques -------------------------- 
     116 
     117   // Retourne le nom de l'élément racine du document xml. 
     118   const std::string & CXMLNode::GetRootName(void) 
     119   {  
     120      return (CXMLNode::RootName);  
     121   } 
    22122 
    23123} // namespace xml 
  • XMLIO_V2/dev/dev_rv/src4/xmlio/xml/xml_node.hpp

    r215 r216  
    1414 */ 
    1515 
     16#ifndef __XIOS_NO_EXTERN 
     17 
    1618// C++ standard headers 
    1719#include <string> 
     
    2123// rapidXML headers 
    2224#include <rapidxml.hpp> 
     25 
     26#endif // __XIOS_NO_EXTERN 
    2327 
    2428// XMLIOServer headers 
     
    3135   namespace xml 
    3236   { 
     37      /** 
     38       * \class CXMLNode 
     39       * \brief Classe de gestion des noeuds dans les documents XML. 
     40       */ 
    3341      class CXMLNode 
    3442      { 
  • XMLIO_V2/dev/dev_rv/src4/xmlio/xml/xml_parser.hpp

    r215 r216  
    1414 */ 
    1515 
     16#ifndef __XIOS_NO_EXTERN 
     17 
    1618// C++ standard headers 
    1719#include <string> 
    1820#include <iostream> 
     21 
     22#endif // __XIOS_NO_EXTERN 
    1923 
    2024// XMLIOServer headers 
Note: See TracChangeset for help on using the changeset viewer.