MongoDB C++ Driver current
Loading...
Searching...
No Matches
Public Types | Public Member Functions | List of all members
bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator > Class Template Reference

#include <bsoncxx/v_noabi/bsoncxx/vector/iterators.hpp>

Description

template<typename Iterator>
class bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >

Iterator for bytes within a packed_bit vector.

Template Parameters
IteratorUnderlying byte iterator type

Public Types

using difference_type = std::ptrdiff_t
 A signed byte count.
 
using iterator_category = std::random_access_iterator_tag
 This is a standard random-access iterator.
 
using pointer = elements::packed_bit_byte< Iterator > const *
 Element pointers aren't really a useful concept here, but this is defined for compatibility with standard random-access iterators.
 
using reference = elements::packed_bit_byte< Iterator > const
 References to individual bytes are each bsoncxx::v_noabi::elements::packed_bit_byte, to protect the validity of bytes with reserved portions.
 
using value_type = std::uint8_t
 Values pointed to by this iterator are unsigned bytes.
 

Public Member Functions

constexpr bool operator!= (packed_bit_byte const &other) const noexcept
 Compare two byte iterators.
 
constexpr reference operator* () const noexcept
 Dereference the byte iterator.
 
constexpr packed_bit_byte operator+ (difference_type const &other) const noexcept
 Calculate a signed addition of this iterator with a ptrdiff_t, moving it forward or backward the indicated number of bytes. If the iterator goes out of range, behavior is undefined.
 
packed_bit_byteoperator++ () noexcept
 Pre-increment.
 
packed_bit_byte operator++ (int) noexcept
 Post-increment.
 
packed_bit_byteoperator+= (difference_type const &other) noexcept
 Advance this iterator forward by the indicated number of bytes.
 
constexpr packed_bit_byte operator- (difference_type const &other) const noexcept
 Calculate a signed subtraction of a ptrdiff_t from this iterator, moving it backward or forward the indicated number of bytes. If the iterator goes out of range, behavior is undefined.
 
constexpr difference_type operator- (packed_bit_byte const &other) const noexcept
 Calculate the difference in position between two byte iterators If the two iterators do not point into the same vector, behavior is undefined.
 
packed_bit_byteoperator-- () noexcept
 Pre-decrement.
 
packed_bit_byte operator-- (int) noexcept
 Post-decrement.
 
packed_bit_byteoperator-= (difference_type const &other) noexcept
 Move this iterator backward by the indicated number of bytes.
 
constexpr bool operator< (packed_bit_byte const &other) const noexcept
 Compare two byte iterators.
 
constexpr bool operator<= (packed_bit_byte const &other) const noexcept
 Compare two byte iterators.
 
constexpr bool operator== (packed_bit_byte const &other) const noexcept
 Compare two byte iterators.
 
constexpr bool operator> (packed_bit_byte const &other) const noexcept
 Compare two byte iterators.
 
constexpr bool operator>= (packed_bit_byte const &other) const noexcept
 Compare two byte iterators.
 

Member Typedef Documentation

◆ difference_type

template<typename Iterator >
using bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::difference_type = std::ptrdiff_t

A signed byte count.

◆ iterator_category

template<typename Iterator >
using bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::iterator_category = std::random_access_iterator_tag

This is a standard random-access iterator.

◆ pointer

template<typename Iterator >
using bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::pointer = elements::packed_bit_byte<Iterator> const*

Element pointers aren't really a useful concept here, but this is defined for compatibility with standard random-access iterators.

◆ reference

template<typename Iterator >
using bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::reference = elements::packed_bit_byte<Iterator> const

References to individual bytes are each bsoncxx::v_noabi::elements::packed_bit_byte, to protect the validity of bytes with reserved portions.

◆ value_type

template<typename Iterator >
using bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::value_type = std::uint8_t

Values pointed to by this iterator are unsigned bytes.

Member Function Documentation

◆ operator!=()

template<typename Iterator >
constexpr bool bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::operator!= ( packed_bit_byte< Iterator > const &  other) const
inlineconstexprnoexcept

Compare two byte iterators.

◆ operator*()

template<typename Iterator >
constexpr reference bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::operator* ( ) const
inlineconstexprnoexcept

Dereference the byte iterator.

Returns
A bsoncxx::v_noabi::elements::packed_bit_byte that can be used like a byte reference.

◆ operator+()

template<typename Iterator >
constexpr packed_bit_byte bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::operator+ ( difference_type const &  other) const
inlineconstexprnoexcept

Calculate a signed addition of this iterator with a ptrdiff_t, moving it forward or backward the indicated number of bytes. If the iterator goes out of range, behavior is undefined.

◆ operator++() [1/2]

template<typename Iterator >
packed_bit_byte & bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::operator++ ( )
inlinenoexcept

Pre-increment.

◆ operator++() [2/2]

template<typename Iterator >
packed_bit_byte bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::operator++ ( int  )
inlinenoexcept

Post-increment.

◆ operator+=()

template<typename Iterator >
packed_bit_byte & bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::operator+= ( difference_type const &  other)
inlinenoexcept

Advance this iterator forward by the indicated number of bytes.

◆ operator-() [1/2]

template<typename Iterator >
constexpr packed_bit_byte bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::operator- ( difference_type const &  other) const
inlineconstexprnoexcept

Calculate a signed subtraction of a ptrdiff_t from this iterator, moving it backward or forward the indicated number of bytes. If the iterator goes out of range, behavior is undefined.

◆ operator-() [2/2]

template<typename Iterator >
constexpr difference_type bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::operator- ( packed_bit_byte< Iterator > const &  other) const
inlineconstexprnoexcept

Calculate the difference in position between two byte iterators If the two iterators do not point into the same vector, behavior is undefined.

◆ operator--() [1/2]

template<typename Iterator >
packed_bit_byte & bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::operator-- ( )
inlinenoexcept

Pre-decrement.

◆ operator--() [2/2]

template<typename Iterator >
packed_bit_byte bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::operator-- ( int  )
inlinenoexcept

Post-decrement.

◆ operator-=()

template<typename Iterator >
packed_bit_byte & bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::operator-= ( difference_type const &  other)
inlinenoexcept

Move this iterator backward by the indicated number of bytes.

◆ operator<()

template<typename Iterator >
constexpr bool bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::operator< ( packed_bit_byte< Iterator > const &  other) const
inlineconstexprnoexcept

Compare two byte iterators.

◆ operator<=()

template<typename Iterator >
constexpr bool bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::operator<= ( packed_bit_byte< Iterator > const &  other) const
inlineconstexprnoexcept

Compare two byte iterators.

◆ operator==()

template<typename Iterator >
constexpr bool bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::operator== ( packed_bit_byte< Iterator > const &  other) const
inlineconstexprnoexcept

Compare two byte iterators.

◆ operator>()

template<typename Iterator >
constexpr bool bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::operator> ( packed_bit_byte< Iterator > const &  other) const
inlineconstexprnoexcept

Compare two byte iterators.

◆ operator>=()

template<typename Iterator >
constexpr bool bsoncxx::v_noabi::vector::iterators::packed_bit_byte< Iterator >::operator>= ( packed_bit_byte< Iterator > const &  other) const
inlineconstexprnoexcept

Compare two byte iterators.


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