|
BDE 4.14.0 Production release
|
#include <bdlb_transformiterator.h>
Public Types | |
| typedef Traits::iterator_category | iterator_category |
| typedef Traits::value_type | value_type |
| typedef Traits::difference_type | difference_type |
| typedef Traits::pointer | pointer |
| typedef Traits::reference | reference |
The transform iterator class itself. Its job is to hold a functor and an iterator, pass through all iterator-related operations to the held iterator, and on dereference, call the functor on the result of dereferencing the iterator and return the result of the call instead.
| typedef Traits::difference_type bdlb::TransformIterator< FUNCTOR, ITERATOR >::difference_type |
| typedef Traits::iterator_category bdlb::TransformIterator< FUNCTOR, ITERATOR >::iterator_category |
| typedef Traits::pointer bdlb::TransformIterator< FUNCTOR, ITERATOR >::pointer |
| typedef Traits::reference bdlb::TransformIterator< FUNCTOR, ITERATOR >::reference |
| typedef Traits::value_type bdlb::TransformIterator< FUNCTOR, ITERATOR >::value_type |
|
inlineexplicit |
Create a TransformIterator object whose underlying iterator and functor have default values. Optionally specify a basicAllocator used to supply memory. If basicAllocator is 0, the currently installed default allocator is used.
|
inline |
Create a TransformIterator object using the specified iterator and functor. Optionally specify a basicAllocator used to supply memory. If basicAllocator is 0, the currently installed default allocator is used.
|
inline |
Create a TransformIterator object having the same value as the specified original object. Optionally specify a basicAllocator used to supply memory. If basicAllocator is 0, the currently installed default allocator is used.
|
default |
| bdlb::TransformIterator< FUNCTOR, ITERATOR >::BSLMF_NESTED_TRAIT_DECLARATION_IF | ( | TransformIterator< FUNCTOR, ITERATOR > | , |
| bslma::UsesBslmaAllocator | , | ||
| bslma::UsesBslmaAllocator< ITERATOR >::value||bslma::UsesBslmaAllocator< FUNCTOR > ::value | |||
| ) |
|
inline |
Return a reference providing modifiable access to the functor of this object.
|
inline |
|
inline |
Return a reference providing modifiable access to the underlying iterator of this object.
|
inline |
Return a const reference to the underlying iterator of this object.
|
inline |
Return the result of applying the functor of this object to the result of dereferencing the underlying iterator. The behavior is undefined if dereferencing the underlying iterator is undefined. Note that the behavior of this method is equivalent to:
|
inline |
|
inline |
Increment the underlying iterator of this object, and return a reference providing modifiable access to this object. The behavior is undefined if incrementing the underlying iterator is undefined.
|
inline |
Advance the underlying iterator of this object by the specified (signed) offset, and return a reference providing modifiable access to this object. The behavior is undefined if so advancing the underlying iterator is undefined.
|
inline |
Decrement the underlying iterator of this object, and return a reference providing modifiable access to this object. The behavior is undefined if decrementing the underlying iterator is undefined.
|
inline |
Regress the underlying iterator of this object by the specified (signed) offset, and return a reference providing modifiable access to this object. The behavior is undefined if so regressing the underlying iterator is undefined.
|
inline |
Return the address of the result of applying the functor of this object to the result of dereferencing the underlying iterator. The behavior is undefined if dereferencing the underlying iterator is undefined. Note that the behavior of this method is equivalent to:
Also note that the functor must return a reference type for this method to be used.
|
inline |
Return the address of the result of applying the functor of this object to the result of dereferencing the underlying iterator. The behavior is undefined if dereferencing the underlying iterator is undefined. Note that the behavior of this method is equivalent to:
Also note that the functor must return a reference type for this method to be used.
|
inline |
Assign to this object the value of the specified rhs object, and return a reference providing modifiable access to this object.
|
inline |
Return the result of applying the functor of this object to the result of dereferencing the underlying iterator advanced by the specified (signed) offset. The behavior is undefined if so advancing or dereferencing the underlying iterator is undefined. Note that the behavior of this method is equivalent to:
|
inline |
Return the result of applying the functor of this object to the result of dereferencing the underlying iterator advanced by the specified (signed) offset. The behavior is undefined if so advancing or dereferencing the underlying iterator is undefined. Note that the behavior of this method is equivalent to:
|
inline |
Efficiently exchange the value of this object with the value of the specified other object by applying swap to each of the functor and underlying iterator fields of the two objects.