Карта сайта Kansoftware
НОВОСТИУСЛУГИРЕШЕНИЯКОНТАКТЫ
Разработка программного обеспечения

Class template interval_base_set

Boost , Chapter 1. Boost.Icl , Header <boost/icl/interval_base_set.hpp>

Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

PrevUpHomeNext

Class template interval_base_set

boost::icl::interval_base_set — Implements a set as a set of intervals (base class)

Synopsis

// In header: <boost/icl/interval_base_set.hpp>
template<typename SubType, typename DomainT, 
         ICL_COMPARE Compare = ICL_COMPARE_INSTANCE(ICL_COMPARE_DEFAULT, DomainT), 
         ICL_INTERVAL(ICL_COMPARE) Interval = ICL_INTERVAL_INSTANCE(ICL_INTERVAL_DEFAULT, DomainT, Compare), 
         ICL_ALLOC Alloc = std::allocator> 
class interval_base_set {
public:
  // types
  typedef interval_base_set< SubType, DomainT, Compare, Interval, Alloc >   type;                          
  typedef SubType                                                           sub_type;                        // The designated derived or sub_type of this base class. 
  typedef type                                                              overloadable_type;               // Auxilliary type for overloadresolution. 
  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_type                                                     segment_type;                    // The segment type of the set. 
  typedef difference_type_of< domain_type >::type                           difference_type;                 // The difference type of an interval which is sometimes different form the data_type. 
  typedef size_type_of< domain_type >::type                                 size_type;                       // The size type of an interval which is mostly std::size_t. 
  typedef exclusive_less_than< interval_type >                              interval_compare;                // Comparison functor for intervals. 
  typedef exclusive_less_than< interval_type >                              key_compare;                     // Comparison functor for keys. 
  typedef ICL_IMPL_SPACE::set< DomainT, domain_compare, Alloc< DomainT > >  atomized_type;                   // The atomized type representing the corresponding container of elements. 
  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 ICL_IMPL_SPACE::set< interval_type, key_compare, allocator_type > ImplSetT;                        // Container type for the implementation. 
  typedef ImplSetT::key_type                                                key_type;                        // key type of the implementing container 
  typedef ImplSetT::key_type                                                data_type;                       // data type of the implementing container 
  typedef ImplSetT::value_type                                              value_type;                      // value type of the implementing container 
  typedef ImplSetT::pointer                                                 pointer;                         // pointer type 
  typedef ImplSetT::const_pointer                                           const_pointer;                   // const pointer type 
  typedef ImplSetT::reference                                               reference;                       // reference type 
  typedef ImplSetT::const_reference                                         const_reference;                 // const reference type 
  typedef ImplSetT::iterator                                                iterator;                        // iterator for iteration over intervals 
  typedef ImplSetT::const_iterator                                          const_iterator;                  // const_iterator for iteration over intervals 
  typedef ImplSetT::reverse_iterator                                        reverse_iterator;                // iterator for reverse iteration over intervals 
  typedef ImplSetT::const_reverse_iterator                                  const_reverse_iterator;          // const_iterator for iteration over intervals 
  typedef boost::icl::element_iterator< iterator >                          element_iterator;                // element iterator: Depreciated, see documentation. 
  typedef boost::icl::element_iterator< const_iterator >                    element_const_iterator;          // element const iterator: Depreciated, see documentation. 
  typedef boost::icl::element_iterator< reverse_iterator >                  element_reverse_iterator;        // element reverse iterator: Depreciated, see documentation. 
  typedef boost::icl::element_iterator< const_reverse_iterator >            element_const_reverse_iterator;  // element const reverse iterator: Depreciated, see documentation. 
  // construct/copy/destruct
  interval_base_set();
  interval_base_set(const interval_base_set &);
  interval_base_set(interval_base_set &&);
  interval_base_set & operator=(interval_base_set);
  // public member functions
  typedef ICL_INTERVAL_TYPE(Interval, DomainT, Compare);
  typedef ICL_COMPARE_DOMAIN(Compare, DomainT);
  typedef ICL_COMPARE_DOMAIN(Compare, segment_type);
   BOOST_STATIC_CONSTANT(int, fineness = 0);
  void swap(interval_base_set &);
  void clear();
  bool empty() const;
  size_type size() const;
  std::size_t iterative_size() const;
  const_iterator find(const element_type &) const;
  const_iterator find(const interval_type &) const;
  SubType & add(const element_type &);
  SubType & add(const segment_type &);
  iterator add(iterator, const segment_type &);
  SubType & subtract(const element_type &);
  SubType & subtract(const segment_type &);
  SubType & insert(const element_type &);
  SubType & insert(const segment_type &);
  iterator insert(iterator, const segment_type &);
  SubType & erase(const element_type &);
  SubType & erase(const segment_type &);
  void erase(iterator);
  void erase(iterator, iterator);
  SubType & flip(const element_type &);
  SubType & flip(const segment_type &);
  iterator begin();
  iterator end();
  const_iterator begin() const;
  const_iterator end() const;
  reverse_iterator rbegin();
  reverse_iterator rend();
  const_reverse_iterator rbegin() const;
  const_reverse_iterator rend() const;
  iterator lower_bound(const value_type &);
  iterator upper_bound(const value_type &);
  const_iterator lower_bound(const value_type &) const;
  const_iterator upper_bound(const value_type &) const;
  std::pair< iterator, iterator > equal_range(const key_type &);
  std::pair< const_iterator, const_iterator > 
  equal_range(const key_type &) const;
  // private member functions
  iterator _add(const segment_type &);
  iterator _add(iterator, const segment_type &);
  // protected member functions
  void add_front(const interval_type &, iterator &);
  void add_main(interval_type &, iterator &, const iterator &);
  void add_segment(const interval_type &, iterator &);
  void add_rear(const interval_type &, iterator &);
  sub_type * that();
  const sub_type * that() const;
};

Description

interval_base_set public construct/copy/destruct

  1. интервал_база_набор();

    Конструктор по умолчанию для пустого объекта

  2. интервал_base_setconstинтервал_base_set&src];

    Конструктор копий

  3. интервал_base_setинтервал_base_set&&src;

    Переместить конструктор

  4. интервал_base_set&оператор=интервал_base_setsrc;

    Переместить оператор назначения

interval_base_set public member functions

  1. typedefICL_INTERVAL_TYPEInterval,DomainT,Compare;
    Тип интервала набора.
  2. typedefICL_COMPARE_DOMAINСравните,DomainT;
    Сравнительный функтор для значений домена.
  3. typedefICL_COMPARE_DOMAINСравните,сегмент_тип;
  4. BOOST_STATIC_CONSTANTint,тонкость=0;
  5. voidswapinterval_base_set&operand;

    swap the content of containers

  6. пустотачистота;

    оставляет контейнер пустым

  7. boolemptyconst;

    является контейнер пустым?

  8. size_typesizeconst;

    Размер интервала — это его кардинальность

    .
  9. std::size_titerative_sizeconst;

    Размер итерации над этим контейнером

  10. const_iteratorfindconstelement_type&key_value]const;

    Найдите интервал, который содержит элементkey_value

  11. const_iteratorfindconstinterval_type&key_interval]const;

    Найдите первый интервал, который сталкивается с интерваломkey_interval

  12. Подтип&добавитьконстэлемент_type&ключ];

    Добавить в набор один элементключ

  13. Подтип&добавитьконстсегмент_type&интервал];

    Добавить интервал элементовинтервалв набор

  14. итератордобавитьитераторprior_,constsegment_type&inter_val;

    Добавить в набор интервал элементовinter_val. Итераторprior_является подсказкой к положениюinter_valможет быть вставлен после.

  15. SubType&вычестьconstэлемент_type&ключ;

    Вычтите один элементключиз набора

  16. SubType&вычитаютconstсегмент_type&inter_val;

    Вычтите интервал элементовinter_valиз множества

  17. Подтип&вставитьконстэлемент_type&ключ;

    Вставить элементключв набор

  18. Подтип&вставитьконстсегмент_type&интервал;

    Включить интервал элементовinter_valв набор

  19. итераторвставитьитераторprior_,constсегмент_тип&inter_val];

    Вставьте интервал элементовinter_valв набор. Итераторprior_является подсказкой к положениюinter_valможет быть вставлен после.

  20. Подтип&стеретьконстэлемент_type&ключ;

    Стереть элементключиз набора

  21. SubType&eraseconstsegment_type&inter_val;

    Удаление интервала элементовinter_valиз множества

  22. пустотастираниеитераторположение;

    Удалите интервал, на который указывает итератор.

  23. пустотастираниеитераторпервый,итераторпрошлый;

    Стирайте все интервалы в диапазоне[первый, последний]итераторов.

  24. SubType&flipconstelement_type&ключ;

    Если* этотнабор содержитключ, он стирается, в противном случае его добавляют.

  25. SubType&flipconstsegment_type&inter_val];

    Если* этотнабор содержитinter_val, он стирается, в противном случае его добавляют.

  26. итераторначинают;
  27. итераторконец;
  28. const_iteratorstartconst;
  29. const_iteratorendconst;
  30. reverse_iteratorrbegin;
  31. reverse_iteratorrend;
  32. const_reverse_iteratorrbeginconst;
  33. const_reverse_iteratorrendconst;
  34. итераторнижний_связанныйконстзначение_тип&интервал;
  35. итераторверхний_связанныйконстзначение_тип&интервал;
  36. const_iteratorlower_boundconstvalue_type&интервал]const;
  37. const_iteratorupper_boundconstvalue_type&интервал]const;
  38. std::пара<итератор,итератор>равный_диапазонконстключ_тип&интервал;
  39. std::pair<const_iterator,const_iterator>equal_rangeconst&интервалconst;

interval_base_set private member functions

  1. итератор_addconstсегмент_type&добавление;
  2. итератор_addитератордо,констсегмент_тип&добавление;

interval_base_set protected member functions

  1. voidadd_frontconstinterval_type&inter_val,iterator&first_;
  2. voidadd_maininterval_type&inter_val,Iterator&iteratorconstiterator&last_;
  3. voidadd_segmentconstinterval_type&inter_val,iterator&it_];
  4. voidadd_rearconstinterval_type&inter_val,iterator&it_];
  5. sub_type*, что;
  6. constsub_type*, чтоconst;

PrevUpHomeNext

Статья Class template interval_base_set раздела Chapter 1. Boost.Icl Header <boost/icl/interval_base_set.hpp> может быть полезна для разработчиков на c++ и boost.




Материалы статей собраны из открытых источников, владелец сайта не претендует на авторство. Там где авторство установить не удалось, материал подаётся без имени автора. В случае если Вы считаете, что Ваши права нарушены, пожалуйста, свяжитесь с владельцем сайта.



:: Главная :: Header <boost/icl/interval_base_set.hpp> ::


реклама


©KANSoftWare (разработка программного обеспечения, создание программ, создание интерактивных сайтов), 2007
Top.Mail.Ru

Время компиляции файла: 2024-08-30 11:47:00
2025-05-20 02:32:36/0.0085330009460449/1