Ignore:
Timestamp:
06/04/10 16:18:34 (14 years ago)
Author:
ymipsl
Message:
 
File:
1 edited

Legend:

Unmodified
Added
Removed
  • XMLIO_V2/dev/trunk/src/XMLIO/declare_attribut.hpp

    r79 r98  
    1 #ifndef DECLARE_ATTRIBUT_HPP 
    2 #define DECLARE_ATTRIBUT_HPP 
     1#ifndef __DECLARE_ATTRIBUT__ 
     2#define __DECLARE_ATTRIBUT__ 
     3 
    34#include "attribut.hpp" 
    45 
    5 #define DECLARE_ATTR(att_name,att_type)                      \ 
    6   class attr_##att_name : public CAttribut<att_type>                         \ 
    7   {                                                          \ 
    8     public:                                                  \ 
    9     const char * getName(void) const { return #att_name ;} ; \ 
    10     attr_##att_name(void) : CAttribut<att_type>() {} ; \ 
    11     attr_##att_name(const att_type& value_) : CAttribut<att_type>(value_) {} ; \ 
    12     attr_##att_name(const attr_##att_name & att) : CAttribut<att_type>(att) {} ; \ 
    13   } att_name 
     6#define DECLARE_ATTR(att_name,att_type)               \ 
     7   class attr_##att_name : public Attribut<att_type>  \ 
     8   {                                                  \ 
     9      public:                                         \ 
     10         const char * getName(void) const { return #att_name ;}                     \ 
     11         virtual const char * getType(void) const { return #att_type ;}             \ 
     12         attr_##att_name(void) : Attribut<att_type>() {}                            \ 
     13         attr_##att_name(const att_type& value_) : Attribut<att_type>(value_) {}    \ 
     14         attr_##att_name(const attr_##att_name & att) : Attribut<att_type>(att) {}  \ 
     15   } att_name 
    1416 
    15 #endif 
     17#endif // __DECLARE_ATTRIBUT__ 
Note: See TracChangeset for help on using the changeset viewer.