1#ifndef included_AMP_Variable_h
2#define included_AMP_Variable_h
4#include "AMP/utils/Units.h"
5#include "AMP/utils/enable_shared_from_this.h"
80 virtual std::string
className()
const {
return "Variable"; }
100 std::shared_ptr<Variable>
clone()
const;
106 virtual std::shared_ptr<Variable>
clone(
const std::string &name )
const;
Class to manage reading/writing restart data.
A description of the data in the vector.
Variable(int64_t fid)
Read restart data to file.
virtual ~Variable()
Destructor.
auto & getName() const
A function that returns the name of a variable.
virtual std::string className() const
A function that returns the name of a variable.
Variable(const std::string &name)
Construct a variable with a name.
virtual void writeRestart(int64_t fid) const
Write restart data to file.
virtual std::shared_ptr< VectorSelector > createVectorSelector() const
Create a VectorSelector.
virtual bool operator==(const Variable &rhs) const
Compares two variables for equality.
virtual const Units & getUnits() const
Get the units of this variable.
virtual std::shared_ptr< Variable > clone(const std::string &name) const
Create a variable of the same type with a new name.
std::string d_VariableName
A name given to the variable.
std::shared_ptr< Variable > clone() const
Create a variable of the same type with a new name.
virtual uint64_t getID() const
Get a unique id hash for the vector.
virtual void setUnits(const Units &u)
Set the units of this variable.
bool operator!=(const Variable &rhs) const
Inverse of ==.
virtual void registerChildObjects(AMP::IO::RestartManager *manager) const
Register any child objects.
AMP::Units d_Units
The units this variable is measured in.
Provides a class for storing units.
Enhancement of std::enable_shared_from_this.
UpdateState
The four states a Vector can be in.
ScatterType
Flag to choose algorithm for makeConsistent.