BDE 4.14.0 Production release
Loading...
Searching...
No Matches
bdlt::CalendarReverseIteratorAdapter< ITERATOR > Class Template Reference

#include <bdlt_calendarreverseiteratoradapter.h>

Public Types

typedef ITERATOR::value_type value_type
 
typedef ITERATOR::difference_type difference_type
 
typedef ITERATOR::pointer pointer
 
typedef ITERATOR::reference reference
 

Public Member Functions

 CalendarReverseIteratorAdapter ()
 
 CalendarReverseIteratorAdapter (const ITERATOR &value)
 
CalendarReverseIteratorAdapteroperator= (const CalendarReverseIteratorAdapter &rhs)
 
CalendarReverseIteratorAdapteroperator= (const ITERATOR &rhs)
 
CalendarReverseIteratorAdapteroperator++ ()
 
CalendarReverseIteratorAdapteroperator-- ()
 
reference operator* () const
 
pointer operator-> () const
 
ITERATOR forwardIterator () const
 

Detailed Description

template<class ITERATOR>
class bdlt::CalendarReverseIteratorAdapter< ITERATOR >

This reverse iterator adapter provides a subset of the bsl::reverse_iterator interface that can be used with the calendar iterators defined in bdlt. Specifically, the types value_type, difference_type , pointer, and reference are defined but iterator_category is not defined (since this is not a fully-compliant iterator). Furthermore, the methods appropriate for random-access iterators are not included (e.g., operator+=).

See bdlt_calendarreverseiteratoradapter

Member Typedef Documentation

◆ difference_type

template<class ITERATOR >
typedef ITERATOR::difference_type bdlt::CalendarReverseIteratorAdapter< ITERATOR >::difference_type

◆ pointer

template<class ITERATOR >
typedef ITERATOR::pointer bdlt::CalendarReverseIteratorAdapter< ITERATOR >::pointer

◆ reference

template<class ITERATOR >
typedef ITERATOR::reference bdlt::CalendarReverseIteratorAdapter< ITERATOR >::reference

◆ value_type

template<class ITERATOR >
typedef ITERATOR::value_type bdlt::CalendarReverseIteratorAdapter< ITERATOR >::value_type

Constructor & Destructor Documentation

◆ CalendarReverseIteratorAdapter() [1/2]

template<class ITERATOR >
bdlt::CalendarReverseIteratorAdapter< ITERATOR >::CalendarReverseIteratorAdapter ( )
inline

Create a reverse iterator having the default value. The default-constructed reverse iterator does not have a singular value unless an object of the type specified by the template parameter ITERATOR has a singular value after default construction.

◆ CalendarReverseIteratorAdapter() [2/2]

template<class ITERATOR >
bdlt::CalendarReverseIteratorAdapter< ITERATOR >::CalendarReverseIteratorAdapter ( const ITERATOR &  value)
inlineexplicit

Create a reverse iterator referring to the element that precedes, in the forward sequence (or that follows, in the backward sequence) the element referred to by the specified value.

Member Function Documentation

◆ forwardIterator()

template<class ITERATOR >
ITERATOR bdlt::CalendarReverseIteratorAdapter< ITERATOR >::forwardIterator ( ) const
inline

Return the forward iterator referring to the element in the forward sequence after the element referred to by this reverse iterator.

◆ operator*()

template<class ITERATOR >
CalendarReverseIteratorAdapter< ITERATOR >::reference bdlt::CalendarReverseIteratorAdapter< ITERATOR >::operator* ( ) const
inline

Return a reference to the element referred to by this reverse iterator. The behavior is undefined unless this iterator is within the bounds of the underlying sequence.

◆ operator++()

template<class ITERATOR >
CalendarReverseIteratorAdapter< ITERATOR > & bdlt::CalendarReverseIteratorAdapter< ITERATOR >::operator++ ( )
inline

Modify this reverse iterator to refer to the next element in the reverse iteration sequence, and return a reference providing modifiable access to this reverse iterator. The behavior is undefined unless, on entry, this reverse iterator does not have the past-the-end value for a reverse iterator over the underlying sequence.

◆ operator--()

template<class ITERATOR >
CalendarReverseIteratorAdapter< ITERATOR > & bdlt::CalendarReverseIteratorAdapter< ITERATOR >::operator-- ( )
inline

Modify this reverse iterator to refer to the previous element in the reverse iteration sequence, and return a reference providing modifiable access to this reverse iterator. The behavior is undefined unless, on entry, this reverse iterator does not have the same value as a reverse iterator at the start of the underlying sequence.

◆ operator->()

template<class ITERATOR >
CalendarReverseIteratorAdapter< ITERATOR >::pointer bdlt::CalendarReverseIteratorAdapter< ITERATOR >::operator-> ( ) const
inline

Return a pointer to the element referred to by this reverse iterator. The behavior is undefined unless this iterator is within the bounds of the underlying sequence.

◆ operator=() [1/2]

template<class ITERATOR >
CalendarReverseIteratorAdapter< ITERATOR > & bdlt::CalendarReverseIteratorAdapter< ITERATOR >::operator= ( const CalendarReverseIteratorAdapter< ITERATOR > &  rhs)
inline

Assign the value of the specified rhs to this object, and return a reference providing modifiable access to this object.

◆ operator=() [2/2]

template<class ITERATOR >
CalendarReverseIteratorAdapter< ITERATOR > & bdlt::CalendarReverseIteratorAdapter< ITERATOR >::operator= ( const ITERATOR &  rhs)
inline

Set the value of this object to refer to the element that precedes, in the forward sequence (or that follows, in the backward sequence) the element referred to by the specified rhs, and return a reference providing modifiable access to this object.


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