|
SST
15.1.0
StructuralSimulationToolkit
|
ObjectMap representing fundamental types, and classes treated as fundamental types. More...
#include <objectMap.h>
Public Member Functions | |
| virtual void | set_impl (const std::string &value) override |
| Set the value of the object represented as a string. More... | |
| virtual bool | checkValue (const std::string &value) override |
| virtual std::string | get () override |
| Get the value of the object as a string. | |
| bool | isFundamental () override |
| Returns true as object is a fundamental. More... | |
| void * | getAddr () override |
| Get the address of the variable represented by the ObjectMap. More... | |
| ObjectMapFundamental (T *addr) | |
| ~ObjectMapFundamental () override=default | |
| Destructor. More... | |
| ObjectMapFundamental (const ObjectMapFundamental &)=delete | |
| Disallow copying and assignment. | |
| ObjectMapFundamental & | operator= (const ObjectMapFundamental &)=delete |
| std::string | getType () override |
| Return the type represented by this ObjectMap as given by the demangled version of typeid(T).name() More... | |
| ObjectMapComparison * | getComparison (const std::string &name, ObjectMapComparison::Op UNUSED(op), const std::string &value) override |
| ObjectMapComparison * | getComparisonVar (const std::string &name, ObjectMapComparison::Op op, const std::string &name2, ObjectMap *var2) override |
| ObjectBuffer * | getObjectBuffer (const std::string &name, size_t sz) override |
Public Member Functions inherited from SST::Core::Serialization::ObjectMap | |
| ObjectMap ()=default | |
| Default constructor primarily used for the "top" object in the hierarchy. | |
| bool | isReadOnly () |
| Check to see if this object is read-only. More... | |
| void | setReadOnly (bool state=true) |
| Set the read-only state of the object. More... | |
| virtual bool | checkValue (const std::string &UNUSED(value)) |
Check if value string is valid for this type More... | |
| std::string | getName () |
| Get the name of the variable represented by this ObjectMap. More... | |
| std::string | getFullName () |
| Get the full hierarchical name of the variable represented by this ObjectMap, based on the path taken to get to this object. More... | |
| virtual const std::multimap< std::string, ObjectMap * > & | getVariables () |
| Get the list of child variables contained in this ObjectMap. More... | |
| void | incRefCount () |
| Increment the reference counter for this ObjectMap. More... | |
| void | decRefCount () |
| Decrement the reference counter for this ObjectMap. More... | |
| int32_t | getRefCount () |
| Get the current reference count. More... | |
| virtual ObjectMapComparison * | getComparison (const std::string &UNUSED(name), ObjectMapComparison::Op UNUSED(op), const std::string &UNUSED(value)) |
| Get a watch point for this object. More... | |
| virtual ObjectMapComparison * | getComparisonVar (const std::string &UNUSED(name), ObjectMapComparison::Op UNUSED(op), const std::string &UNUSED(name2), ObjectMap *UNUSED(var2)) |
| virtual ObjectBuffer * | getObjectBuffer (const std::string &UNUSED(name), size_t UNUSED(sz)) |
| ObjectMap * | selectParent () |
| Get the parent for this ObjectMap. More... | |
| ObjectMap * | selectVariable (std::string name, bool &loop_detected) |
| Get the ObjectMap for the specified variable. More... | |
| virtual void | addVariable (const std::string &UNUSED(name), ObjectMap *UNUSED(obj)) |
| Adds a variable to this ObjectMap. More... | |
| void | set (const std::string &value) |
| Sets the value of the variable represented by the ObjectMap to the specified value, which is represented as a string. More... | |
| virtual std::string | get (const std::string &var) |
| Gets the value of the specified variable as a string. More... | |
| virtual void | set (const std::string &var, const std::string &value, bool &found, bool &read_only) |
| Sets the value of the specified variable to the specified value, which is represented as a string. More... | |
| virtual bool | isContainer () |
| Check to see if this ObjectMap represents a container. More... | |
| virtual | ~ObjectMap ()=default |
| Destructor. More... | |
| ObjectMap (const ObjectMap &)=delete | |
| Disallow copying and assignment. | |
| ObjectMap & | operator= (const ObjectMap &)=delete |
| virtual std::string | listVariable (std::string name, bool &found, int recurse=0) |
| Create a string that lists information for the specified variable. More... | |
| virtual std::string | list (int recurse=0) |
| Create a string that lists information for the current object. More... | |
| virtual ObjectMap * | findVariable (const std::string &name) |
| Find a variable in this object map. More... | |
Protected Attributes | |
| T * | addr_ = nullptr |
| Address of the variable for reading and writing. | |
Protected Attributes inherited from SST::Core::Serialization::ObjectMap | |
| ObjectMapMetaData * | mdata_ = nullptr |
| Metadata object for walking the object hierarchy. More... | |
| bool | read_only_ = false |
| Indicates whether or not the variable is read-only. | |
Additional Inherited Members | |
Static Public Member Functions inherited from SST::Core::Serialization::ObjectMap | |
| static std::string | demangle_name (const char *name) |
| Static function to demangle type names returned from typeid(T).name() More... | |
Protected Member Functions inherited from SST::Core::Serialization::ObjectMap | |
| virtual void | set_impl (const std::string &UNUSED(value)) |
| Function implemented by derived classes to implement set(). More... | |
| virtual void | activate_callback () |
| Function that will get called when this object is selected. | |
| virtual void | deactivate_callback () |
| Function that will get called when this object is deactivated (i.e selectParent() is called) | |
Static Protected Attributes inherited from SST::Core::Serialization::ObjectMap | |
| static const std::multimap< std::string, ObjectMap * > | emptyVars |
| Static empty variable map for use by versions that don't have variables (i.e. More... | |
ObjectMap representing fundamental types, and classes treated as fundamental types.
In order for an object to be treated as a fundamental, it must be printable using SST::Core::to_string() and assignable using SST::Core::from_string(). If this is not true, it is possible to create a template specialization for the type desired to be treated as a fundamental. The specialization will need to provide the functions for getting and setting the values as a string.
|
overridedefault |
Destructor.
Should not be called directly (i.e. do not call delete on the object). Call decRefCount() when object is no longer needed. This will also call decRefCount() on all its children.
|
inlineoverridevirtual |
Get the address of the variable represented by the ObjectMap.
Implements SST::Core::Serialization::ObjectMap.
References SST::Core::Serialization::ObjectMapFundamental< T >::addr_.
|
inlineoverridevirtual |
Return the type represented by this ObjectMap as given by the demangled version of typeid(T).name()
Implements SST::Core::Serialization::ObjectMap.
References SST::Core::Serialization::ObjectMap::demangle_name().
|
inlineoverridevirtual |
Returns true as object is a fundamental.
Reimplemented from SST::Core::Serialization::ObjectMap.
|
inlineoverridevirtual |
Set the value of the object represented as a string.
| value | Value to set the underlying object to, represented as a string |
References SST::Core::Serialization::ObjectMapFundamental< T >::addr_.