Function endian_store

Synopsis

#include "breeze/endianness/endian_codec.hpp"

template <typename EndianPolicy, typename T, typename ForwardIter>
void endian_store(T const &value, ForwardIter it)

Description

Convenience wrapper around endian_codec::encode()

endian_store< EndianPolicy( value, it ) > is equivalent to:

typedef typename std::iterator_traits< ForwardIter >::value_type
                    Byte ;
breeze::endian_codec< EndianPolicy, T, Byte >::encode( value, it ) ;
Note
This can't be used for purely output iterators, because they don't have a notion of value_type.

Source

Lines 273-280 in breeze/endianness/endian_codec.hpp.

template< typename EndianPolicy, typename T, typename ForwardIter >
void
endian_store( T const & value, ForwardIter it )
{
    typedef typename std::iterator_traits< ForwardIter >::value_type
                        Byte ;
    breeze::endian_codec< EndianPolicy, T, Byte >::encode( value, it ) ;
}