Field3D
|
#include <FieldMetadata.h>
Public Types | |
typedef std::map< std::string, float > | FloatMetadata |
typedef std::map< std::string, int > | IntMetadata |
typedef std::map< std::string, std::string > | StrMetadata |
typedef std::map< std::string, V3f > | VecFloatMetadata |
typedef std::map< std::string, V3i > | VecIntMetadata |
Public Member Functions | |
void | operator= (const FieldMetadata &other) |
Constructors & destructor | |
FieldMetadata (CallBack_T *owner) | |
virtual | ~FieldMetadata () |
Metadata | |
V3f | vecFloatMetadata (const std::string &name, const V3f &defaultVal) const |
Tries to retrieve a V3f metadata value. Returns the specified default value if no metadata was found. More... | |
float | floatMetadata (const std::string &name, const float defaultVal) const |
Tries to retrieve a float metadata value. Returns the specified default value if no metadata was found. More... | |
V3i | vecIntMetadata (const std::string &name, const V3i &defaultVal) const |
Tries to retrieve a V3i metadata value. Returns the specified default value if no metadata was found. More... | |
int | intMetadata (const std::string &name, const int defaultVal) const |
Tries to retrieve an int metadata value. Returns the specified default value if no metadata was found. More... | |
std::string | strMetadata (const std::string &name, const std::string &defaultVal) const |
Tries to retrieve a string metadata value. Returns the specified default value if no metadata was found. More... | |
const VecFloatMetadata & | vecFloatMetadata () const |
Read only access to the m_vecFloatMetadata dictionary. More... | |
const FloatMetadata & | floatMetadata () const |
Read only access to the m_floatMetadata dictionary. More... | |
const VecIntMetadata & | vecIntMetadata () const |
Read only access to the m_vecIntMetadata dictionary. More... | |
const IntMetadata & | intMetadata () const |
Read only access to the m_intMetadata dictionary. More... | |
const StrMetadata & | strMetadata () const |
Read only access to the m_strMetadata dictionary. More... | |
void | setVecFloatMetadata (const std::string &name, const V3f &val) |
Set the a V3f value for the given metadata name. More... | |
void | setFloatMetadata (const std::string &name, const float val) |
Set the a float value for the given metadata name. More... | |
void | setVecIntMetadata (const std::string &name, const V3i &val) |
Set the a V3i value for the given metadata name. More... | |
void | setIntMetadata (const std::string &name, const int val) |
Set the a int value for the given metadata name. More... | |
void | setStrMetadata (const std::string &name, const std::string &val) |
Set the a string value for the given metadata name. More... | |
Private Member Functions | |
FieldMetadata (const FieldMetadata &) | |
Private Attributes | |
FloatMetadata | m_floatMetadata |
Float metadata. More... | |
IntMetadata | m_intMetadata |
Int metadata. More... | |
CallBack_T * | m_owner |
Pointer to owner. It is assumed that this has a lifetime at least as long as the Metadata instance. More... | |
StrMetadata | m_strMetadata |
String metadata. More... | |
VecFloatMetadata | m_vecFloatMetadata |
V3f metadata. More... | |
VecIntMetadata | m_vecIntMetadata |
V3i metadata. More... | |
Definition at line 69 of file FieldMetadata.h.
typedef std::map<std::string, std::string> FieldMetadata< CallBack_T >::StrMetadata |
Definition at line 75 of file FieldMetadata.h.
typedef std::map<std::string, int> FieldMetadata< CallBack_T >::IntMetadata |
Definition at line 76 of file FieldMetadata.h.
typedef std::map<std::string, float> FieldMetadata< CallBack_T >::FloatMetadata |
Definition at line 77 of file FieldMetadata.h.
typedef std::map<std::string, V3i> FieldMetadata< CallBack_T >::VecIntMetadata |
Definition at line 78 of file FieldMetadata.h.
typedef std::map<std::string, V3f> FieldMetadata< CallBack_T >::VecFloatMetadata |
Definition at line 79 of file FieldMetadata.h.
|
inline |
Definition at line 86 of file FieldMetadata.h.
Referenced by FieldMetadata< FieldBase >::strMetadata().
|
inlinevirtual |
Definition at line 90 of file FieldMetadata.h.
|
private |
|
inline |
Definition at line 96 of file FieldMetadata.h.
V3f FieldMetadata< CallBack_T >::vecFloatMetadata | ( | const std::string & | name, |
const V3f & | defaultVal | ||
) | const |
Tries to retrieve a V3f metadata value. Returns the specified default value if no metadata was found.
Definition at line 258 of file FieldMetadata.h.
References FieldMetadata< CallBack_T >::m_vecFloatMetadata.
Referenced by Field3DOutputFile::writeMetadata().
float FieldMetadata< CallBack_T >::floatMetadata | ( | const std::string & | name, |
const float | defaultVal | ||
) | const |
Tries to retrieve a float metadata value. Returns the specified default value if no metadata was found.
Definition at line 274 of file FieldMetadata.h.
References FieldMetadata< CallBack_T >::m_floatMetadata.
Referenced by ProceduralField< Data_T >::typedFloatMetadata(), and Field3DOutputFile::writeMetadata().
V3i FieldMetadata< CallBack_T >::vecIntMetadata | ( | const std::string & | name, |
const V3i & | defaultVal | ||
) | const |
Tries to retrieve a V3i metadata value. Returns the specified default value if no metadata was found.
Definition at line 290 of file FieldMetadata.h.
References FieldMetadata< CallBack_T >::m_vecIntMetadata.
Referenced by Field3DOutputFile::writeMetadata().
int FieldMetadata< CallBack_T >::intMetadata | ( | const std::string & | name, |
const int | defaultVal | ||
) | const |
Tries to retrieve an int metadata value. Returns the specified default value if no metadata was found.
Definition at line 306 of file FieldMetadata.h.
References FieldMetadata< CallBack_T >::m_intMetadata.
Referenced by ProceduralField< Data_T >::typedIntMetadata(), and Field3DOutputFile::writeMetadata().
std::string FieldMetadata< CallBack_T >::strMetadata | ( | const std::string & | name, |
const std::string & | defaultVal | ||
) | const |
Tries to retrieve a string metadata value. Returns the specified default value if no metadata was found.
Definition at line 322 of file FieldMetadata.h.
References FIELD3D_NAMESPACE_HEADER_CLOSE, and FieldMetadata< CallBack_T >::m_strMetadata.
Referenced by Field3DOutputFile::writeMetadata().
|
inline |
Read only access to the m_vecFloatMetadata dictionary.
Definition at line 132 of file FieldMetadata.h.
Referenced by FieldMetadata< FieldBase >::operator=().
|
inline |
Read only access to the m_floatMetadata dictionary.
Definition at line 136 of file FieldMetadata.h.
Referenced by FieldMetadata< FieldBase >::operator=().
|
inline |
Read only access to the m_vecIntMetadata dictionary.
Definition at line 140 of file FieldMetadata.h.
Referenced by FieldMetadata< FieldBase >::operator=().
|
inline |
Read only access to the m_intMetadata dictionary.
Definition at line 144 of file FieldMetadata.h.
Referenced by FieldMetadata< FieldBase >::operator=().
|
inline |
Read only access to the m_strMetadata dictionary.
Definition at line 148 of file FieldMetadata.h.
Referenced by FieldMetadata< FieldBase >::operator=().
void FieldMetadata< CallBack_T >::setVecFloatMetadata | ( | const std::string & | name, |
const V3f & | val | ||
) |
Set the a V3f value for the given metadata name.
Definition at line 198 of file FieldMetadata.h.
References FieldMetadata< CallBack_T >::m_owner, and FieldMetadata< CallBack_T >::m_vecFloatMetadata.
Referenced by Field3DInputFile::readMetadata(), and FieldMetadata< FieldBase >::strMetadata().
void FieldMetadata< CallBack_T >::setFloatMetadata | ( | const std::string & | name, |
const float | val | ||
) |
Set the a float value for the given metadata name.
Definition at line 210 of file FieldMetadata.h.
References FieldMetadata< CallBack_T >::m_floatMetadata, and FieldMetadata< CallBack_T >::m_owner.
Referenced by Field3DInputFile::readMetadata(), and FieldMetadata< FieldBase >::strMetadata().
void FieldMetadata< CallBack_T >::setVecIntMetadata | ( | const std::string & | name, |
const V3i & | val | ||
) |
Set the a V3i value for the given metadata name.
Definition at line 222 of file FieldMetadata.h.
References FieldMetadata< CallBack_T >::m_owner, and FieldMetadata< CallBack_T >::m_vecIntMetadata.
Referenced by Field3DInputFile::readMetadata(), and FieldMetadata< FieldBase >::strMetadata().
void FieldMetadata< CallBack_T >::setIntMetadata | ( | const std::string & | name, |
const int | val | ||
) |
Set the a int value for the given metadata name.
Definition at line 234 of file FieldMetadata.h.
References FieldMetadata< CallBack_T >::m_intMetadata, and FieldMetadata< CallBack_T >::m_owner.
Referenced by Field3DInputFile::readMetadata(), Field3DInputFile::readProxyLayer(), and FieldMetadata< FieldBase >::strMetadata().
void FieldMetadata< CallBack_T >::setStrMetadata | ( | const std::string & | name, |
const std::string & | val | ||
) |
Set the a string value for the given metadata name.
Definition at line 246 of file FieldMetadata.h.
References FieldMetadata< CallBack_T >::m_owner, and FieldMetadata< CallBack_T >::m_strMetadata.
Referenced by Field3DInputFile::readMetadata(), and FieldMetadata< FieldBase >::strMetadata().
|
private |
V3f metadata.
Definition at line 177 of file FieldMetadata.h.
Referenced by FieldMetadata< FieldBase >::operator=(), FieldMetadata< CallBack_T >::setVecFloatMetadata(), FieldMetadata< CallBack_T >::vecFloatMetadata(), and FieldMetadata< FieldBase >::vecFloatMetadata().
|
private |
Float metadata.
Definition at line 179 of file FieldMetadata.h.
Referenced by FieldMetadata< CallBack_T >::floatMetadata(), FieldMetadata< FieldBase >::floatMetadata(), FieldMetadata< FieldBase >::operator=(), and FieldMetadata< CallBack_T >::setFloatMetadata().
|
private |
V3i metadata.
Definition at line 181 of file FieldMetadata.h.
Referenced by FieldMetadata< FieldBase >::operator=(), FieldMetadata< CallBack_T >::setVecIntMetadata(), FieldMetadata< CallBack_T >::vecIntMetadata(), and FieldMetadata< FieldBase >::vecIntMetadata().
|
private |
Int metadata.
Definition at line 183 of file FieldMetadata.h.
Referenced by FieldMetadata< CallBack_T >::intMetadata(), FieldMetadata< FieldBase >::intMetadata(), FieldMetadata< FieldBase >::operator=(), and FieldMetadata< CallBack_T >::setIntMetadata().
|
private |
String metadata.
Definition at line 185 of file FieldMetadata.h.
Referenced by FieldMetadata< FieldBase >::operator=(), FieldMetadata< CallBack_T >::setStrMetadata(), FieldMetadata< CallBack_T >::strMetadata(), and FieldMetadata< FieldBase >::strMetadata().
|
private |
Pointer to owner. It is assumed that this has a lifetime at least as long as the Metadata instance.
Definition at line 189 of file FieldMetadata.h.
Referenced by FieldMetadata< CallBack_T >::setFloatMetadata(), FieldMetadata< CallBack_T >::setIntMetadata(), FieldMetadata< CallBack_T >::setStrMetadata(), FieldMetadata< CallBack_T >::setVecFloatMetadata(), and FieldMetadata< CallBack_T >::setVecIntMetadata().