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

Class template permutation_iterator

Boost , Chapter 1. Boost.Compute , Reference

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 permutation_iterator

boost::compute::permutation_iterator — The permutation_iterator class provides a permuation iterator.

Synopsis

// In header: <boost/compute/iterator/permutation_iterator.hpp>
template<typename ElementIterator, typename IndexIterator> 
class permutation_iterator {
public:
  // types
  typedef unspecified                 super_type;     
  typedef super_type::value_type      value_type;     
  typedef super_type::reference       reference;      
  typedef super_type::base_type       base_type;      
  typedef super_type::difference_type difference_type;
  typedef IndexIterator               index_iterator; 
  // construct/copy/destruct
  permutation_iterator(ElementIterator, IndexIterator);
  permutation_iterator(const permutation_iterator< ElementIterator, IndexIterator > &);
  permutation_iterator< ElementIterator, IndexIterator > & 
  operator=(const permutation_iterator< ElementIterator, IndexIterator > &);
  ~permutation_iterator();
  // public member functions
  size_t get_index() const;
  const buffer & get_buffer() const;
  template<typename IndexExpr> unspecified operator[](const IndexExpr &) const;
  // private member functions
  reference dereference() const;
};

Description

Итератор перестановок повторяется в диапазоне значений и в диапазоне индексов. При отмене он возвращает значение из диапазона значений, используя текущий индекс из диапазона индексов.

Например, для изменения диапазона с помощью алгоритма копирования() и последовательности перестановок:

Смотрите также:

make_permutation_iterator()

permutation_iterator public construct/copy/destruct

  1. <
    permutation_iterator(ElementIteratore,IndexIteratori);
    >
  2. <
    permutation_iterator(constpermutation_iterator<ElementIterator,IndexIterator>&other);
    >
  3. <
    permutation_iterator<ElementIterator,IndexIterator>&
    operator=(constpermutation_iterator<ElementIterator,IndexIterator>&other);
    >
  4. <
    ~permutation_iterator();
    >

permutation_iterator public member functions

  1. <
    size_tget_index()const;
    >
  2. <
    constbuffer&get_buffer()const;
    >
  3. <
    template<typenameIndexExpr>
     unspecifiedoperator[](constIndexExpr&expr)const;
    >

permutation_iterator private member functions

  1. <
    referencedereference()const;
    >

PrevUpHomeNext

Статья Class template permutation_iterator раздела Chapter 1. Boost.Compute Reference может быть полезна для разработчиков на c++ и boost.




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



:: Главная :: Reference ::


реклама


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

Время компиляции файла: 2024-08-30 11:47:00
2025-05-20 16:20:54/0.0036861896514893/0