Serialbox  2.2.0
Data serialization library and tools for C/C++, Python and Fortran
serialbox::FieldMetainfoImpl Class Reference

Meta-information of a data field. More...

#include <FieldMetainfoImpl.h>

Public Member Functions

 FieldMetainfoImpl ()
 Default constructor.
 
 FieldMetainfoImpl (TypeID type, const std::vector< int > &dims, const MetainfoMapImpl &metaInfo)
 Construct members externally.
 
 FieldMetainfoImpl (TypeID type, const std::vector< int > &dims)
 Construct members externally.
 
 FieldMetainfoImpl (const json::json &jsonNode)
 Construct from JSON.
 
 FieldMetainfoImpl (const FieldMetainfoImpl &other)
 Copy constructor.
 
 FieldMetainfoImpl (FieldMetainfoImpl &&)=default
 Move constructor.
 
FieldMetainfoImploperator= (const FieldMetainfoImpl &other)
 Copy assignment.
 
FieldMetainfoImploperator= (FieldMetainfoImpl &&)=default
 Move assignment.
 
void swap (FieldMetainfoImpl &other) noexcept
 Swap with other.
 
bool operator== (const FieldMetainfoImpl &right) const noexcept
 Test for equality.
 
bool operator!= (const FieldMetainfoImpl &right) const noexcept
 Test for inequality.
 
TypeIDtype () noexcept
 Access TypeID.
 
const TypeIDtype () const noexcept
 
std::vector< int > & dims () noexcept
 Access dimensions.
 
const std::vector< int > & dims () const noexcept
 
MetainfoMapImplmetaInfo () noexcept
 Access meta-info map.
 
const MetainfoMapImplmetaInfo () const noexcept
 
json::json toJSON () const
 Convert to JSON.
 
void fromJSON (const json::json &jsonNode)
 Construct from JSON node. More...
 
std::string toString () const
 Convert to string.
 
std::shared_ptr< MetainfoMapImpl > & metaInfoPtr () noexcept
 Get meta-info pointer.
 
const std::shared_ptr< MetainfoMapImpl > & metaInfoPtr () const noexcept
 

Friends

std::ostream & operator<< (std::ostream &stream, const FieldMetainfoImpl &f)
 Convert to stream.
 

Detailed Description

Meta-information of a data field.

Definition at line 29 of file FieldMetainfoImpl.h.

Member Function Documentation

◆ fromJSON()

void serialbox::FieldMetainfoImpl::fromJSON ( const json::json &  jsonNode)

Construct from JSON node.

Exceptions
ExceptionJSON node is ill-formed

Definition at line 54 of file FieldMetainfoImpl.cpp.


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