Bitcoin Core  0.15.99
P2P Digital Currency
Public Member Functions | Protected Attributes | List of all members
BigEndian< I > Class Template Reference

Serialization wrapper class for big-endian integers. More...

#include <serialize.h>

Public Member Functions

 BigEndian (I &val)
 
template<typename Stream >
void Serialize (Stream &s) const
 
template<typename Stream >
void Unserialize (Stream &s)
 

Protected Attributes

I & m_val
 

Detailed Description

template<typename I>
class BigEndian< I >

Serialization wrapper class for big-endian integers.

Use this wrapper around integer types that are stored in memory in native byte order, but serialized in big endian notation. This is only intended to implement serializers that are compatible with existing formats, and its use is not recommended for new data structures.

Only 16-bit types are supported for now.

Definition at line 440 of file serialize.h.

Constructor & Destructor Documentation

template<typename I>
BigEndian< I >::BigEndian ( I &  val)
inlineexplicit

Definition at line 445 of file serialize.h.

Member Function Documentation

template<typename I>
template<typename Stream >
void BigEndian< I >::Serialize ( Stream &  s) const
inline

Definition at line 452 of file serialize.h.

Here is the call graph for this function:

template<typename I>
template<typename Stream >
void BigEndian< I >::Unserialize ( Stream &  s)
inline

Definition at line 458 of file serialize.h.

Here is the call graph for this function:

Member Data Documentation

template<typename I>
I& BigEndian< I >::m_val
protected

Definition at line 443 of file serialize.h.


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