Version: 8.3.0
SALOMEDSImpl_ScalarVariable Class Reference

#include <SALOMEDSImpl_ScalarVariable.hxx>

Inheritance diagram for SALOMEDSImpl_ScalarVariable:

Public Types

enum  VariableTypes { REAL_VAR, INTEGER_VAR, BOOLEAN_VAR, STRING_VAR }
 

Public Member Functions

 SALOMEDSImpl_ScalarVariable (SALOMEDSImpl_GenericVariable::VariableTypes theType, const std::string &theName)
 Function : SALOMEDSImpl_ScalarVariable Purpose : More...
 
 ~SALOMEDSImpl_ScalarVariable ()
 Function : ~SALOMEDSImpl_ScalarVariable() Purpose : More...
 
bool setValue (const double theValue)
 Function : Purpose : More...
 
double getValue () const
 Function : getValue() Purpose : More...
 
bool setStringValue (const std::string &theValue)
 Function : Purpose : More...
 
std::string getStringValue () const
 Function : getStringValue() Purpose : More...
 
virtual std::string Save () const
 Function : Save() Purpose : More...
 
virtual std::string SaveToScript () const
 Function : SaveToScript() Purpose : More...
 
virtual std::string SaveType () const
 Function : SaveType() Purpose : More...
 
virtual void Load (const std::string &theStrValue)
 Function : Load() Purpose : More...
 
VariableTypes Type () const
 Function : Type Purpose : More...
 
std::string Name () const
 Function : Name Purpose : More...
 
bool setType (const VariableTypes theType)
 Function : setType Purpose : More...
 
bool setName (const std::string &theName)
 Function : setName Purpose : More...
 

Static Public Member Functions

static VariableTypes String2VariableType (const std::string &theStrType)
 Function : String2VariableType Purpose : More...
 

Private Attributes

double myValue
 
std::string myStrValue
 

Member Enumeration Documentation

Enumerator
REAL_VAR 
INTEGER_VAR 
BOOLEAN_VAR 
STRING_VAR 

Constructor & Destructor Documentation

SALOMEDSImpl_ScalarVariable::SALOMEDSImpl_ScalarVariable ( SALOMEDSImpl_GenericVariable::VariableTypes  theType,
const std::string &  theName 
)

Function : SALOMEDSImpl_ScalarVariable Purpose :

SALOMEDSImpl_ScalarVariable::~SALOMEDSImpl_ScalarVariable ( )

Function : ~SALOMEDSImpl_ScalarVariable() Purpose :

Member Function Documentation

std::string SALOMEDSImpl_ScalarVariable::getStringValue ( ) const

Function : getStringValue() Purpose :

References myStrValue.

double SALOMEDSImpl_ScalarVariable::getValue ( ) const

Function : getValue() Purpose :

References myValue.

void SALOMEDSImpl_ScalarVariable::Load ( const std::string &  theStrValue)
virtual
std::string SALOMEDSImpl_GenericVariable::Name ( ) const
inherited
std::string SALOMEDSImpl_ScalarVariable::SaveType ( ) const
virtual

Function : SaveType() Purpose :

Reimplemented from SALOMEDSImpl_GenericVariable.

References SALOMEDSImpl_GenericVariable::Type().

bool SALOMEDSImpl_GenericVariable::setName ( const std::string &  theName)
inherited

Function : setName Purpose :

References SALOMEDSImpl_GenericVariable::_name.

Referenced by SALOMEDSImpl_Study::RenameVariable().

bool SALOMEDSImpl_ScalarVariable::setStringValue ( const std::string &  theValue)

Function : Purpose :

References myStrValue.

Referenced by Load(), and SALOMEDSImpl_Study::SetStringVariable().

bool SALOMEDSImpl_GenericVariable::setType ( const VariableTypes  theType)
inherited

Function : setType Purpose :

References SALOMEDSImpl_GenericVariable::_type.

bool SALOMEDSImpl_ScalarVariable::setValue ( const double  theValue)

Function : Purpose :

References myValue.

Referenced by Load(), and SALOMEDSImpl_Study::SetVariable().

SALOMEDSImpl_GenericVariable::VariableTypes SALOMEDSImpl_GenericVariable::String2VariableType ( const std::string &  theStrType)
staticinherited

Function : String2VariableType Purpose :

Referenced by ReadNoteBookVariables().

SALOMEDSImpl_GenericVariable::VariableTypes SALOMEDSImpl_GenericVariable::Type ( ) const
inherited

Function : Type Purpose :

References SALOMEDSImpl_GenericVariable::_type.

Referenced by SALOMEDSImpl_Study::IsTypeOf(), Load(), Save(), SaveToScript(), and SaveType().

Field Documentation

std::string SALOMEDSImpl_ScalarVariable::myStrValue
private
double SALOMEDSImpl_ScalarVariable::myValue
private

Referenced by getValue(), Save(), SaveToScript(), and setValue().