00001 
00002 
00003 
00004 
00005 
00006 
00007 
00008 
00009 
00010 
00011 
00012 
00013 
00014 
00015 
00016 
00017 #ifndef VCSN_AUTOMATA_IMPLEMENTATION_GEOMETRY_HH
00018 # define VCSN_AUTOMATA_IMPLEMENTATION_GEOMETRY_HH
00019 
00020 # include <map>
00021 # include <string>
00022 # include <vaucanson/automata/concept/handlers.hh>
00023 
00024 
00025 namespace vcsn
00026 {
00035   template<typename HState, typename HTransition, typename Coords>
00036   struct geometry
00037   {
00038     typedef HState hstate_t;
00039     typedef HTransition htransition_t;
00040     typedef Coords coords_t;
00041 
00042       
00043       typedef std::map<hstate_t, coords_t>
00044       states_geometry_map_t;
00045 
00046       
00047       typedef std::map<htransition_t, coords_t>
00048       transitions_geometry_map_t;
00049 
00050       
00051       typedef std::map<hstate_t, coords_t>
00052       initials_geometry_map_t;
00053 
00054       
00055       typedef std::map<hstate_t, coords_t>
00056       finals_geometry_map_t;
00057 
00058       geometry();
00059       explicit geometry(const geometry& obj);
00060       ~geometry();
00061       geometry& operator=(const geometry& obj);
00062       geometry& copy_from(const geometry& obj);
00063 
00068       states_geometry_map_t& states();
00069       const states_geometry_map_t& states() const;
00070 
00075       transitions_geometry_map_t& transitions();
00076       const transitions_geometry_map_t& transitions() const;
00077 
00082       initials_geometry_map_t& initials();
00083       const initials_geometry_map_t& initials() const;
00084 
00089       finals_geometry_map_t& finals();
00090       const finals_geometry_map_t& finals() const;
00091 
00096       std::string& name();
00097       const std::string& name() const;
00098 
00099 
00100     private:
00101       mutable states_geometry_map_t*    states_;
00102       mutable transitions_geometry_map_t*       transitions_;
00103       mutable initials_geometry_map_t*  initials_;
00104       mutable finals_geometry_map_t*    finals_;
00105       mutable std::string*              name_;
00106   };
00107 
00108 } 
00109 
00110 
00111 
00112 # if !defined VCSN_USE_INTERFACE_ONLY || defined VCSN_USE_LIB
00113 #  include <vaucanson/automata/implementation/geometry.hxx>
00114 # endif // VCSN_USE_INTERFACE_ONLY
00115 
00116 #endif // ! VCSN_AUTOMATA_IMPLEMENTATION_GEOMETRY_HH