lemon/maps.h
changeset 1830 ffd6d50fb155
parent 1778 4ba7965386fb
child 1875 98698b69a902
equal deleted inserted replaced
16:98a025c87cea 17:6a417c98e699
   856   template <typename M> 
   856   template <typename M> 
   857   inline NotMap<M> notMap(const M &m) {
   857   inline NotMap<M> notMap(const M &m) {
   858     return NotMap<M>(m);
   858     return NotMap<M>(m);
   859   }
   859   }
   860 
   860 
   861   /// \brief Writeable bool map for store each true assigned elements.
   861   /// \brief Writable bool map for store each true assigned elements.
   862   ///
   862   ///
   863   /// Writeable bool map for store each true assigned elements. It will
   863   /// Writable bool map for store each true assigned elements. It will
   864   /// copies all the true setted keys to the given iterator.
   864   /// copies all the true setted keys to the given iterator.
   865   ///
   865   ///
   866   /// \note The container of the iterator should contain for each element.
   866   /// \note The container of the iterator should contain for each element.
   867   template <typename _Iterator>
   867   template <typename _Iterator>
   868   class StoreBoolMap {
   868   class StoreBoolMap {
   894     
   894     
   895   private:
   895   private:
   896     Iterator _begin, _end;
   896     Iterator _begin, _end;
   897   };
   897   };
   898 
   898 
   899   /// \brief Writeable bool map for store each true assigned elements in 
   899   /// \brief Writable bool map for store each true assigned elements in 
   900   /// a back insertable container.
   900   /// a back insertable container.
   901   ///
   901   ///
   902   /// Writeable bool map for store each true assigned elements in a back 
   902   /// Writable bool map for store each true assigned elements in a back 
   903   /// insertable container. It will push back all the true setted keys into
   903   /// insertable container. It will push back all the true setted keys into
   904   /// the container.
   904   /// the container.
   905   template <typename Container>
   905   template <typename Container>
   906   class BackInserterBoolMap {
   906   class BackInserterBoolMap {
   907   public:
   907   public:
   920     
   920     
   921   private:
   921   private:
   922     Container& container;    
   922     Container& container;    
   923   };
   923   };
   924 
   924 
   925   /// \brief Writeable bool map for store each true assigned elements in 
   925   /// \brief Writable bool map for store each true assigned elements in 
   926   /// a front insertable container.
   926   /// a front insertable container.
   927   ///
   927   ///
   928   /// Writeable bool map for store each true assigned elements in a front 
   928   /// Writable bool map for store each true assigned elements in a front 
   929   /// insertable container. It will push front all the true setted keys into
   929   /// insertable container. It will push front all the true setted keys into
   930   /// the container.
   930   /// the container.
   931   template <typename Container>
   931   template <typename Container>
   932   class FrontInserterBoolMap {
   932   class FrontInserterBoolMap {
   933   public:
   933   public:
   946     
   946     
   947   private:
   947   private:
   948     Container& container;    
   948     Container& container;    
   949   };
   949   };
   950 
   950 
   951   /// \brief Writeable bool map for store each true assigned elements in 
   951   /// \brief Writable bool map for store each true assigned elements in 
   952   /// an insertable container.
   952   /// an insertable container.
   953   ///
   953   ///
   954   /// Writeable bool map for store each true assigned elements in an 
   954   /// Writable bool map for store each true assigned elements in an 
   955   /// insertable container. It will insert all the true setted keys into
   955   /// insertable container. It will insert all the true setted keys into
   956   /// the container.
   956   /// the container.
   957   template <typename Container>
   957   template <typename Container>
   958   class InserterBoolMap {
   958   class InserterBoolMap {
   959   public:
   959   public:
   974     Container& container;    
   974     Container& container;    
   975   };
   975   };
   976 
   976 
   977   /// \brief Fill the true setted elements with a given value.
   977   /// \brief Fill the true setted elements with a given value.
   978   ///
   978   ///
   979   /// Writeable bool map for fill the true setted elements with a given value.
   979   /// Writable bool map for fill the true setted elements with a given value.
   980   /// The value can be setted 
   980   /// The value can be setted 
   981   /// the container.
   981   /// the container.
   982   template <typename Map>
   982   template <typename Map>
   983   class FillBoolMap {
   983   class FillBoolMap {
   984   public:
   984   public:
  1014     Map& map;
  1014     Map& map;
  1015     typename Map::Value fill;
  1015     typename Map::Value fill;
  1016   };
  1016   };
  1017 
  1017 
  1018 
  1018 
  1019   /// \brief Writeable bool map which stores for each true assigned elements  
  1019   /// \brief Writable bool map which stores for each true assigned elements  
  1020   /// the setting order number.
  1020   /// the setting order number.
  1021   ///
  1021   ///
  1022   /// Writeable bool map which stores for each true assigned elements  
  1022   /// Writable bool map which stores for each true assigned elements  
  1023   /// the setting order number.
  1023   /// the setting order number.
  1024   template <typename Map>
  1024   template <typename Map>
  1025   class SettingOrderBoolMap {
  1025   class SettingOrderBoolMap {
  1026   public:
  1026   public:
  1027     typedef typename Map::Key Key;
  1027     typedef typename Map::Key Key;