RawSpeed
fast raw decoding library
Loading...
Searching...
No Matches
rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType > Class Template Reference

#include "adt/CoalescingOutputIterator.h"

Collaboration diagram for rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >:
[legend]

Classes

struct  DummyContainerType

Public Types

using iterator_concept = std::output_iterator_tag
using value_type = void
using difference_type = ptrdiff_t
using pointer = void
using reference = void
using container_type = DummyContainerType

Public Member Functions

 CoalescingOutputIterator ()=delete
template<typename U>
requires std::same_as<UnderlyingOutputIterator, std::remove_reference_t<U>>
 CoalescingOutputIterator (U &&it_)
 CoalescingOutputIterator (const CoalescingOutputIterator &other)
 CoalescingOutputIterator (CoalescingOutputIterator &&other) noexcept
CoalescingOutputIteratoroperator= (const CoalescingOutputIterator &other)
CoalescingOutputIteratoroperator= (CoalescingOutputIterator &&other) noexcept
 ~CoalescingOutputIterator ()
CoalescingOutputIteratoroperator* ()
CoalescingOutputIteratoroperator++ ()
CoalescingOutputIterator operator++ (int)
template<typename U>
requires std::same_as<U, PartType>
CoalescingOutputIteratoroperator= (U part)

Private Member Functions

void establishClassInvariants () const
void maybeOutputCoalescedParts ()

Private Attributes

UnderlyingOutputIterator it
CoalescedType cache = 0
int occupancy = 0

Static Private Attributes

static constexpr int MaxOccupancy = bitwidth<CoalescedType>()

Detailed Description

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
requires (std::output_iterator<UnderlyingOutputIterator, CoalescedType> && std::unsigned_integral<CoalescedType> && std::unsigned_integral<PartType> && sizeof(PartType) <= sizeof(CoalescedType) && sizeof(CoalescedType) % sizeof(PartType) == 0)
class rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >

Definition at line 42 of file CoalescingOutputIterator.h.

Member Typedef Documentation

◆ container_type

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
using rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::container_type = DummyContainerType

Definition at line 78 of file CoalescingOutputIterator.h.

◆ difference_type

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
using rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::difference_type = ptrdiff_t

Definition at line 74 of file CoalescingOutputIterator.h.

◆ iterator_concept

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
using rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::iterator_concept = std::output_iterator_tag

Definition at line 72 of file CoalescingOutputIterator.h.

◆ pointer

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
using rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::pointer = void

Definition at line 75 of file CoalescingOutputIterator.h.

◆ reference

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
using rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::reference = void

Definition at line 76 of file CoalescingOutputIterator.h.

◆ value_type

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
using rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::value_type = void

Definition at line 73 of file CoalescingOutputIterator.h.

Constructor & Destructor Documentation

◆ CoalescingOutputIterator() [1/4]

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::CoalescingOutputIterator ( )
delete

Referenced by CoalescingOutputIterator(), CoalescingOutputIterator(), operator*(), operator++(), operator++(), operator=(), operator=(), and operator=().

Here is the caller graph for this function:

◆ CoalescingOutputIterator() [2/4]

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
template<typename U>
requires std::same_as<UnderlyingOutputIterator, std::remove_reference_t<U>>
rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::CoalescingOutputIterator ( U && it_)
inlineexplicit

Definition at line 84 of file CoalescingOutputIterator.h.

References it.

◆ CoalescingOutputIterator() [3/4]

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::CoalescingOutputIterator ( const CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType > & other)
inline

Definition at line 86 of file CoalescingOutputIterator.h.

References CoalescingOutputIterator(), invariant, it, and occupancy.

Here is the call graph for this function:

◆ CoalescingOutputIterator() [4/4]

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::CoalescingOutputIterator ( CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType > && other)
inlinenoexcept

Definition at line 93 of file CoalescingOutputIterator.h.

References CoalescingOutputIterator().

Here is the call graph for this function:

◆ ~CoalescingOutputIterator()

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::~CoalescingOutputIterator ( )
inline

Definition at line 111 of file CoalescingOutputIterator.h.

References establishClassInvariants(), invariant, MaxOccupancy, maybeOutputCoalescedParts(), and occupancy.

Here is the call graph for this function:

Member Function Documentation

◆ establishClassInvariants()

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
void rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::establishClassInvariants ( ) const
inlineprivate

Definition at line 50 of file CoalescingOutputIterator.h.

References rawspeed::bitwidth(), invariant, MaxOccupancy, and occupancy.

Referenced by ~CoalescingOutputIterator(), maybeOutputCoalescedParts(), operator*(), operator++(), operator++(), and operator=().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ maybeOutputCoalescedParts()

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
void rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::maybeOutputCoalescedParts ( )
inlineprivate

Definition at line 56 of file CoalescingOutputIterator.h.

References cache, establishClassInvariants(), rawspeed::getLE(), invariant, it, MaxOccupancy, and occupancy.

Referenced by ~CoalescingOutputIterator(), and operator=().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ operator*()

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
CoalescingOutputIterator & rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::operator* ( )
inlinenodiscard

Definition at line 124 of file CoalescingOutputIterator.h.

References CoalescingOutputIterator(), and establishClassInvariants().

Here is the call graph for this function:

◆ operator++() [1/2]

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
CoalescingOutputIterator & rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::operator++ ( )
inline

Definition at line 129 of file CoalescingOutputIterator.h.

References CoalescingOutputIterator(), and establishClassInvariants().

Here is the call graph for this function:

◆ operator++() [2/2]

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
CoalescingOutputIterator rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::operator++ ( int )
inline

Definition at line 135 of file CoalescingOutputIterator.h.

References CoalescingOutputIterator(), and establishClassInvariants().

Here is the call graph for this function:

◆ operator=() [1/3]

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
CoalescingOutputIterator & rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::operator= ( CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType > && other)
inlinenoexcept

Definition at line 106 of file CoalescingOutputIterator.h.

References CoalescingOutputIterator().

Here is the call graph for this function:

◆ operator=() [2/3]

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
CoalescingOutputIterator & rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::operator= ( const CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType > & other)
inline

Definition at line 98 of file CoalescingOutputIterator.h.

References CoalescingOutputIterator(), invariant, and occupancy.

Here is the call graph for this function:

◆ operator=() [3/3]

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
template<typename U>
requires std::same_as<U, PartType>
CoalescingOutputIterator & rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::operator= ( U part)
inline

Definition at line 142 of file CoalescingOutputIterator.h.

References CoalescingOutputIterator(), rawspeed::bitwidth(), cache, establishClassInvariants(), rawspeed::getLE(), invariant, MaxOccupancy, maybeOutputCoalescedParts(), and occupancy.

Here is the call graph for this function:

Member Data Documentation

◆ cache

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
CoalescedType rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::cache = 0
private

Definition at line 45 of file CoalescingOutputIterator.h.

Referenced by maybeOutputCoalescedParts(), and operator=().

◆ it

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
UnderlyingOutputIterator rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::it
private

◆ MaxOccupancy

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
int rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::MaxOccupancy = bitwidth<CoalescedType>()
staticconstexprprivate

◆ occupancy

template<typename UnderlyingOutputIterator, typename PartType = uint8_t, typename CoalescedType = typename UnderlyingOutputIterator::container_type::value_type>
int rawspeed::CoalescingOutputIterator< UnderlyingOutputIterator, PartType, CoalescedType >::occupancy = 0
private

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