xlnt
Public Types | Public Member Functions | List of all members
xlnt::const_range_iterator Class Reference

A const version of range_iterator which does not allow modification to the dereferenced cell_vector. More...

#include <range_iterator.hpp>

Public Types

using iterator_category = std::bidirectional_iterator_tag
 this iterator meets the interface requirements of bidirection_iterator More...
 
using value_type = const cell_vector
 
using difference_type = std::ptrdiff_t
 
using pointer = const cell_vector *
 
using reference = const cell_vector
 

Public Member Functions

 const_range_iterator ()=default
 Default constructs a range iterator More...
 
 const_range_iterator (const worksheet &ws, const cell_reference &cursor, const range_reference &bounds, major_order order, bool skip_null)
 Constructs a range iterator on a worksheet, cell pointing to the current row or column, range bounds, an order, and whether or not to skip null column/rows. More...
 
 const_range_iterator (const const_range_iterator &)=default
 Default copy constructor. More...
 
const_range_iteratoroperator= (const const_range_iterator &)=default
 Default assignment operator. More...
 
 const_range_iterator (const_range_iterator &&)=default
 Default move constructor. More...
 
const_range_iteratoroperator= (const_range_iterator &&)=default
 Default move assignment operator. More...
 
 ~const_range_iterator ()=default
 Default destructor More...
 
const reference operator* () const
 Dereferennce the iterator to return the current column/row. More...
 
bool operator== (const const_range_iterator &other) const
 Returns true if this iterator is equivalent to other. More...
 
bool operator!= (const const_range_iterator &other) const
 Returns true if this iterator is not equivalent to other. More...
 
const_range_iteratoroperator-- ()
 Pre-decrement the iterator to point to the next row/column. More...
 
const_range_iterator operator-- (int)
 Post-decrement the iterator to point to the next row/column. More...
 
const_range_iteratoroperator++ ()
 Pre-increment the iterator to point to the next row/column. More...
 
const_range_iterator operator++ (int)
 Post-increment the iterator to point to the next row/column. More...
 

Detailed Description

A const version of range_iterator which does not allow modification to the dereferenced cell_vector.

Member Typedef Documentation

◆ iterator_category

using xlnt::const_range_iterator::iterator_category = std::bidirectional_iterator_tag

this iterator meets the interface requirements of bidirection_iterator

Constructor & Destructor Documentation

◆ const_range_iterator() [1/4]

xlnt::const_range_iterator::const_range_iterator ( )
default

Default constructs a range iterator

◆ const_range_iterator() [2/4]

xlnt::const_range_iterator::const_range_iterator ( const worksheet ws,
const cell_reference cursor,
const range_reference bounds,
major_order  order,
bool  skip_null 
)

Constructs a range iterator on a worksheet, cell pointing to the current row or column, range bounds, an order, and whether or not to skip null column/rows.

◆ const_range_iterator() [3/4]

xlnt::const_range_iterator::const_range_iterator ( const const_range_iterator )
default

Default copy constructor.

◆ const_range_iterator() [4/4]

xlnt::const_range_iterator::const_range_iterator ( const_range_iterator &&  )
default

Default move constructor.

◆ ~const_range_iterator()

xlnt::const_range_iterator::~const_range_iterator ( )
default

Default destructor

Member Function Documentation

◆ operator!=()

bool xlnt::const_range_iterator::operator!= ( const const_range_iterator other) const

Returns true if this iterator is not equivalent to other.

◆ operator*()

const reference xlnt::const_range_iterator::operator* ( ) const

Dereferennce the iterator to return the current column/row.

◆ operator++() [1/2]

const_range_iterator& xlnt::const_range_iterator::operator++ ( )

Pre-increment the iterator to point to the next row/column.

◆ operator++() [2/2]

const_range_iterator xlnt::const_range_iterator::operator++ ( int  )

Post-increment the iterator to point to the next row/column.

◆ operator--() [1/2]

const_range_iterator& xlnt::const_range_iterator::operator-- ( )

Pre-decrement the iterator to point to the next row/column.

◆ operator--() [2/2]

const_range_iterator xlnt::const_range_iterator::operator-- ( int  )

Post-decrement the iterator to point to the next row/column.

◆ operator=() [1/2]

const_range_iterator& xlnt::const_range_iterator::operator= ( const const_range_iterator )
default

Default assignment operator.

◆ operator=() [2/2]

const_range_iterator& xlnt::const_range_iterator::operator= ( const_range_iterator &&  )
default

Default move assignment operator.

◆ operator==()

bool xlnt::const_range_iterator::operator== ( const const_range_iterator other) const

Returns true if this iterator is equivalent to other.


The documentation for this class was generated from the following file: