Boost C++ Libraries Home Libraries People FAQ More

PrevUpHomeNext

Class template separate_interval_set

boost::itl::separate_interval_set — Implements a set as a set of intervals - leaving adjoining intervals separate.

Synopsis

template<typename DomainT , 
         ITL_COMPARE Compare = ITL_COMPARE_INSTANCE(std::less, DomainT), 
         template< class, ITL_COMPARE >class Interval = itl::interval, 
         ITL_ALLOC Alloc = std::allocator> 
class separate_interval_set : public boost::itl::interval_base_set< boost::itl::separate_interval_set< DomainT, Compare, Interval, Alloc >, DomainT, Compare, Interval, Alloc >
{
public:
  // types
  typedef interval_base_set< itl::separate_interval_set< DomainT, Compare, Interval, Alloc >, DomainT, Compare, Interval, Alloc > base_type;            
  typedef separate_interval_set< DomainT, Compare, Interval, Alloc >                                                              type;                 
  typedef type                                                                                                                    overloadable_type;      // Auxilliary type for overloadresolution. 
  typedef interval_set< DomainT, Compare, Interval, Alloc >                                                                       joint_type;           
  typedef DomainT                                                                                                                 domain_type;            // The domain type of the set. 
  typedef DomainT                                                                                                                 codomain_type;          // The codomaintype is the same as domain_type. 
  typedef DomainT                                                                                                                 element_type;           // The element type of the set. 
  typedef Interval< DomainT, Compare >                                                                                            interval_type;          // The interval type of the set. 
  typedef interval_type                                                                                                           segment_type;           // The segment type of the set. 
  typedef exclusive_less< interval_type >                                                                                         interval_compare;       // Comparison functor for intervals. 
  typedef exclusive_less< interval_type >                                                                                         key_compare;            // Comparison functor for keys. 
  typedef Alloc< interval_type >                                                                                                  allocator_type;         // The allocator type of the set. 
  typedef Alloc< DomainT >                                                                                                        domain_allocator_type;  // allocator type of the corresponding element set 
  typedef itl::set< DomainT, Compare, Alloc >                                                                                     atomized_type;          // The corresponding atomized type representing this interval container of elements. 
  typedef itl::set< interval_type, ITL_EXCLUSIVE_LESS(interval_type), Alloc >                                                     ImplSetT;               // Container type for the implementation. 
  typedef ImplSetT::key_type                                                                                                      key_type;               // key type of the implementing container 
  typedef ImplSetT::data_type                                                                                                     data_type;              // data type of the implementing container 
  typedef ImplSetT::value_type                                                                                                    value_type;             // value type of the implementing container 
  typedef ImplSetT::iterator                                                                                                      iterator;               // iterator for iteration over intervals 
  typedef ImplSetT::const_iterator                                                                                                const_iterator;         // const_iterator for iteration over intervals 

  // construct/copy/destruct
  separate_interval_set();
  separate_interval_set(const separate_interval_set &);
  template<class SubType > 
    separate_interval_set(const interval_base_set< SubType, DomainT, Compare, Interval, Alloc > &);
  separate_interval_set(const domain_type &);
  separate_interval_set(const interval_type &);
  template<class SubType > 
    separate_interval_set& 
    operator=(const interval_base_set< SubType, DomainT, Compare, Interval, Alloc > &);

  // public member functions
  typedef ITL_COMPARE_DOMAIN(Compare, DomainT) ;
  template<class SubType > 
    void assign(const interval_base_set< SubType, DomainT, Compare, Interval, Alloc > &) ;

  // private member functions
  bool contains_(const interval_type &) const;
  void add_(const value_type &) ;
  iterator add_(iterator, const value_type &) ;
  void subtract_(const value_type &) ;
  void handle_neighbours(const iterator &) ;
};

Description

separate_interval_set public construct/copy/destruct

  1. separate_interval_set();
  2. separate_interval_set(const separate_interval_set & src);
  3. template<class SubType > 
      separate_interval_set(const interval_base_set< SubType, DomainT, Compare, Interval, Alloc > & src);
  4. separate_interval_set(const domain_type & elem);
  5. separate_interval_set(const interval_type & itv);
  6. template<class SubType > 
      separate_interval_set& 
      operator=(const interval_base_set< SubType, DomainT, Compare, Interval, Alloc > & src);

separate_interval_set public member functions

  1. typedef ITL_COMPARE_DOMAIN(Compare, DomainT) ;
  2. template<class SubType > 
      void assign(const interval_base_set< SubType, DomainT, Compare, Interval, Alloc > & src) ;

separate_interval_set private member functions

  1. bool contains_(const interval_type & sub) const;
    sub
  2. void add_(const value_type & addend) ;
    addend
  3. iterator add_(iterator prior_, const value_type & addend) ;
  4. void subtract_(const value_type & minuend) ;
    minuend
  5. void handle_neighbours(const iterator &) ;

PrevUpHomeNext