MFMv2.0.10
Movable Feast Machine Simulator 2.0.10
|
#include <ByteSerializable.h>
Public Types | |
enum | Result { UNSUPPORTED = -1, FAILURE = 0, SUCCESS = 1 } |
Public Member Functions | |
virtual Result | ReadFrom (ByteSource &byteSource, s32 argument=0)=0 |
virtual Result | PrintTo (ByteSink &byteSink, s32 argument=0)=0 |
ByteSerializable is an interface for an object that can either print itself to a ByteSink, read itself from a ByteSource, or both. By default it can do neither; if it can do both, it is strongly expected that the two operations invert each other.
|
pure virtual |
Print a representation of this ByteSerializble to the given byteSink, with its details possibly modified by argument. The meaning of argument is unspecified except that 0 should be interpreted as a request for default, 'no modification', formatting.
Implemented in MFM::AtomicParameter< CC >, MFM::AtomicParameter< T >, MFM::AtomicParameter< MFM::CoreConfig >, MFM::ElementParameterNeighborhood< CC, SITES >, MFM::ElementParameterBool< CC >, MFM::ElementParameterS32< CC >, MFM::ElementParameterU32< CC >, MFM::IPrintMyself, MFM::UUID, MFM::AtomSerializer< CC >, MFM::PacketSerializer< CC >, and MFM::DateTimeStamp.
|
pure virtual |
Modify this object by reading a representation of a ByteSerializable from the given byteSource, with its details possibly modified by argument. The meaning of argument is unspecified except that 0 should be interpreted as a request for default, 'no modification', interpretation.
Implemented in MFM::AtomicParameter< CC >, MFM::AtomicParameter< T >, MFM::AtomicParameter< MFM::CoreConfig >, MFM::ElementParameterNeighborhood< CC, SITES >, MFM::ElementParameterBool< CC >, MFM::ElementParameterS32< CC >, MFM::ElementParameterU32< CC >, MFM::IPrintMyself, MFM::UUID, MFM::PacketSerializer< CC >, MFM::AtomSerializer< CC >, and MFM::DateTimeStamp.