ldas-tools-framecpp 3.0.4
|
Interface to Objects. More...
#include <FrameSpec.hh>
Public Member Functions | |
virtual | ~ObjectInterface () |
Destructor. | |
virtual streamsize_type | Bytes (const stream_base_type &Stream) const =0 |
Return the number of bytes for this object. | |
virtual Object * | Create () const |
constructor - virtual | |
virtual Object * | Create (istream_type &Stream) const =0 |
constructor - virtual | |
virtual Object * | Create (std::istream &Buffer) const |
constructor - virtual | |
virtual bool | operator== (const Object &Obj) const =0 |
comparison operator | |
virtual Object * | Clone () const |
constructor - virtual copy constructor | |
virtual const Description * | GetDescription () const =0 |
Get FrSH/FrSE description of object. | |
virtual const char * | ObjectStructName () const =0 |
Retrieve the class name of the object. | |
virtual void | VerifyObject (Verify &Verifier, IFrameStream &Stream) const |
Verify an object. | |
virtual void | Write (ostream_type &Stream) const =0 |
Write object to the stream. | |
virtual | ~ObjectInterface () |
Destructor. | |
virtual streamsize_type | Bytes (const stream_base_type &Stream) const =0 |
Return the number of bytes for this object. | |
virtual Object * | Create () const |
constructor - virtual | |
virtual Object * | Create (istream_type &Stream) const =0 |
constructor - virtual | |
virtual Object * | Create (std::istream &Buffer) const |
constructor - virtual | |
virtual bool | operator== (const Object &Obj) const =0 |
comparison operator | |
virtual Object * | Clone () const |
constructor - virtual copy constructor | |
virtual const Description * | GetDescription () const =0 |
Get FrSH/FrSE description of object. | |
virtual const char * | ObjectStructName () const =0 |
Retrieve the class name of the object. | |
virtual void | VerifyObject (Verify &Verifier, IFrameStream &Stream) const |
Verify an object. | |
virtual void | Write (ostream_type &Stream) const =0 |
Write object to the stream. | |
Static Public Member Functions | |
static object_type | DemoteObject (frame_spec_version_type Target, object_type Obj, demote_stream_type *Stream) |
Down grade an object. | |
static object_type | PromoteObject (frame_spec_version_type Target, frame_spec_version_type Source, object_type Obj, stream_base_type *Stream) |
Upgrade an object. | |
template<typename PreviousType , typename CurrentType > | |
static object_type | PromoteObject (frame_spec_version_type Target, frame_spec_version_type Source, object_type Obj, stream_base_type *Stream) |
Upgrade an object. | |
static object_type | DemoteObject (frame_spec_version_type Target, object_type Obj, demote_stream_type *Stream) |
Down grade an object. | |
static object_type | PromoteObject (frame_spec_version_type Target, frame_spec_version_type Source, object_type Obj, stream_base_type *Stream) |
Upgrade an object. | |
template<typename PreviousType , typename CurrentType > | |
static object_type | PromoteObject (frame_spec_version_type Target, frame_spec_version_type Source, object_type Obj, stream_base_type *Stream) |
Upgrade an object. | |
Protected Member Functions | |
virtual demote_ret_type | demote (frame_spec_version_type Target, demote_arg_type Obj, demote_stream_type *Stream) const =0 |
Demotes object to previous version of the frame spec. | |
virtual promote_ret_type | promote (frame_spec_version_type Target, promote_arg_type Obj, promote_stream_type *Stream) const =0 |
Promotes object to another version of the frame spec. | |
virtual class_type | getClass () const =0 |
Retrieve the class name associated with the object. | |
virtual demote_ret_type | demote (frame_spec_version_type Target, demote_arg_type Obj, demote_stream_type *Stream) const =0 |
Demotes object to previous version of the frame spec. | |
virtual promote_ret_type | promote (frame_spec_version_type Target, promote_arg_type Obj, promote_stream_type *Stream) const =0 |
Promotes object to another version of the frame spec. | |
virtual class_type | getClass () const =0 |
Retrieve the class name associated with the object. | |
Interface to Objects.
This interface should be the base of all frame objects. It allows for generic handling of frame objects.
|
virtual |
Destructor.
Release the resources back to the system. By being virtual, all the resources associated with any derived class are given a chance for proper cleanup.
|
pure virtual |
Return the number of bytes for this object.
[in] | Stream | The stream on which the object will be written or read. |
Implemented in FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrameH, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrameH, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrameSpec::Object, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrameSpec::Object, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrDetector, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrDetector, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrSH, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrSH, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrTOC, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrTOC, checksum_type >, FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_3::FrameH, FrameCPP::Version_3::FrameH, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrTable, FrameCPP::Version_4::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrHeader, FrameCPP::Version_8::FrHeader, FrameCPP::Version_9::FrHeader, and FrameCPP::Version_9::FrHeader.
|
pure virtual |
Return the number of bytes for this object.
[in] | Stream | The stream on which the object will be written or read. |
Implemented in FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrameH, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrameH, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrameSpec::Object, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrameSpec::Object, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrDetector, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrDetector, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrSH, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrSH, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrTOC, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrTOC, checksum_type >, FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_3::FrameH, FrameCPP::Version_3::FrameH, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrTable, FrameCPP::Version_4::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrHeader, FrameCPP::Version_8::FrHeader, FrameCPP::Version_9::FrHeader, and FrameCPP::Version_9::FrHeader.
|
protectedpure virtual |
Demotes object to previous version of the frame spec.
[in] | Target | The version of the frame specification to demote too. |
[in] | Obj | The version of the object to demote. |
[in] | Stream | The input stream from which the original object was read. |
Implemented in FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrTable, FrameCPP::Version_4::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrHeader, FrameCPP::Version_8::FrHeader, FrameCPP::Version_9::FrHeader, and FrameCPP::Version_9::FrHeader.
|
protectedpure virtual |
Demotes object to previous version of the frame spec.
[in] | Target | The version of the frame specification to demote too. |
[in] | Obj | The version of the object to demote. |
[in] | Stream | The input stream from which the original object was read. |
Implemented in FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrTable, FrameCPP::Version_4::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrHeader, FrameCPP::Version_8::FrHeader, FrameCPP::Version_9::FrHeader, and FrameCPP::Version_9::FrHeader.
|
static |
Down grade an object.
[in] | Target | This is the version of the frame specification of the demoted object. |
[in] | Obj | The base object. |
[in] | Stream | Stream from which Obj was created. |
|
static |
Down grade an object.
[in] | Target | This is the version of the frame specification of the demoted object. |
[in] | Obj | The base object. |
[in] | Stream | Stream from which Obj was created. |
|
pure virtual |
Retrieve the class name of the object.
Implemented in FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_3::FrameH, FrameCPP::Version_3::FrameH, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrTable, FrameCPP::Version_4::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrHeader, FrameCPP::Version_8::FrHeader, FrameCPP::Version_9::FrHeader, and FrameCPP::Version_9::FrHeader.
|
pure virtual |
Retrieve the class name of the object.
Implemented in FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_3::FrameH, FrameCPP::Version_3::FrameH, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrTable, FrameCPP::Version_4::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrHeader, FrameCPP::Version_8::FrHeader, FrameCPP::Version_9::FrHeader, and FrameCPP::Version_9::FrHeader.
|
protectedpure virtual |
Promotes object to another version of the frame spec.
[in] | Target | The version of the promoted frame specification. |
[in] | Obj | The object to be promoted. |
[in] | Stream | The input stream from which the original object was read. |
Implemented in FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrTable, FrameCPP::Version_4::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrHeader, FrameCPP::Version_8::FrHeader, FrameCPP::Version_9::FrHeader, and FrameCPP::Version_9::FrHeader.
|
protectedpure virtual |
Promotes object to another version of the frame spec.
[in] | Target | The version of the promoted frame specification. |
[in] | Obj | The object to be promoted. |
[in] | Stream | The input stream from which the original object was read. |
Implemented in FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrTable, FrameCPP::Version_4::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrHeader, FrameCPP::Version_8::FrHeader, FrameCPP::Version_9::FrHeader, and FrameCPP::Version_9::FrHeader.
|
static |
Upgrade an object.
[in] | Target | Promote Obj to this version of the frame specification. |
[in] | Source | Obj conforms to this version of the frame specification. |
[in] | Obj | Object to be converted |
[in] | Stream | Originating stream for Obj. |
|
static |
Upgrade an object.
[in] | Target | Promote Obj to this version of the frame specification. |
[in] | Source | Obj conforms to this version of the frame specification. |
[in] | Obj | Object to be converted |
[in] | Stream | Originating stream for Obj. |
|
static |
Upgrade an object.
[in] | Target | Promote Obj to this version of the frame specification. |
[in] | Source | Obj conforms to this version of the frame specification. |
[in] | Obj | Object to be converted |
[in] | Stream | Originating stream for Obj. |
|
static |
Upgrade an object.
[in] | Target | Promote Obj to this version of the frame specification. |
[in] | Source | Obj conforms to this version of the frame specification. |
[in] | Obj | Object to be converted |
[in] | Stream | Originating stream for Obj. |
|
virtual |
Verify an object.
[in,out] | Verifier | Set of rules to use in verification of the object. If an error occurs, the violation is logged here. |
[in] | Stream | The stream that is being used to read the object. |
Reimplemented in FrameCPP::Version_3::FrameH, FrameCPP::Version_3::FrameH, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrHeader, FrameCPP::Version_8::FrHeader, FrameCPP::Version_9::FrEndOfFile, FrameCPP::Version_9::FrEndOfFile, FrameCPP::Version_9::FrHeader, and FrameCPP::Version_9::FrHeader.
|
virtual |
Verify an object.
[in,out] | Verifier | Set of rules to use in verification of the object. If an error occurs, the violation is logged here. |
[in] | Stream | The stream that is being used to read the object. |
Reimplemented in FrameCPP::Version_3::FrameH, FrameCPP::Version_3::FrameH, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrHeader, FrameCPP::Version_8::FrHeader, FrameCPP::Version_9::FrEndOfFile, FrameCPP::Version_9::FrEndOfFile, FrameCPP::Version_9::FrHeader, and FrameCPP::Version_9::FrHeader.
|
pure virtual |
Write object to the stream.
[in,out] | Stream | The stream being written with the contents of object. |
Implemented in FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrameH, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrameH, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrameSpec::Object, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrameSpec::Object, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrDetector, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrDetector, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrSH, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrSH, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrTOC, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrTOC, checksum_type >, FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_3::FrameH, FrameCPP::Version_3::FrameH, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrTable, FrameCPP::Version_4::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrHeader, FrameCPP::Version_8::FrHeader, FrameCPP::Version_9::FrHeader, and FrameCPP::Version_9::FrHeader.
|
pure virtual |
Write object to the stream.
[in,out] | Stream | The stream being written with the contents of object. |
Implemented in FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrameH, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrameH, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrameSpec::Object, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrameSpec::Object, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrDetector, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrDetector, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrSH, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrSH, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrTOC, checksum_type >, FrameCPP::Common::FrameSpec::ObjectWithChecksum< Common::FrTOC, checksum_type >, FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::PTR_STRUCT< DC, DI, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Common::StreamRef2< LT, CKT, CT, IT, SPEC_VERSION_T >, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_3::FrAdcData, FrameCPP::Version_3::FrameH, FrameCPP::Version_3::FrameH, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrAdcData, FrameCPP::Version_4::FrTable, FrameCPP::Version_4::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_6::FrTable, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrEndOfFile, FrameCPP::Version_8::FrHeader, FrameCPP::Version_8::FrHeader, FrameCPP::Version_9::FrHeader, and FrameCPP::Version_9::FrHeader.