00001 
00002 
00003 
00004 
00005 
00006 
00007 
00008 
00009 
00010 
00011 
00012 
00013 
00014 
00015 
00016 
00017 #ifndef VCSN_AUTOMATA_IMPLEMENTATION_LISTG_LISTG_HANDLERS_HXX
00018 # define VCSN_AUTOMATA_IMPLEMENTATION_LISTG_LISTG_HANDLERS_HXX
00019 
00020 # include <climits>
00021 # include <vaucanson/misc/contract.hh>
00022 # include <vaucanson/automata/implementation/listg/listg_handlers.hh>
00023 
00024 namespace vcsn
00025 {
00026 
00027   template<typename Tag>
00028   handler<Tag, unsigned>::handler() : v_(UINT_MAX)
00029   {}
00030 
00031   template<typename Tag>
00032   handler<Tag, unsigned>::handler(unsigned h) : v_(h)
00033   {}
00034 
00035   template<typename Tag>
00036   handler<Tag, unsigned>::handler(const handler<Tag, unsigned>& h) : v_(h.v_)
00037   {}
00038 
00039   template<typename Tag>
00040   handler<Tag, unsigned>&
00041   handler<Tag, unsigned>::operator=(const handler<Tag, unsigned>& h)
00042   {
00043     v_ = h.v_;
00044     return *this;
00045   }
00046 
00047   template<typename Tag>
00048   unsigned handler<Tag, unsigned>::value() const
00049   {
00050     return v_;
00051   }
00052 
00053   template<typename Tag>
00054   handler<Tag, unsigned>::operator unsigned() const
00055   {
00056     return v_;
00057   }
00058 
00059   template<typename Tag>
00060   bool
00061   handler<Tag, unsigned>::is_valid() const
00062   {
00063     return v_ != UINT_MAX;
00064   }
00065 
00066 } 
00067 
00068 #endif
00069