SHAPER  9.12.0
XAO::BooleanField Class Reference

Represents a field with boolean values. More...

Inheritance diagram for XAO::BooleanField:
Inheritance graph

Public Member Functions

 BooleanField (XAO::Dimension dimension, int nbElements, int nbComponents, const std::string &name)
 Constructor. More...
 
virtual XAO::Type getType ()
 Gets the Type of the field. More...
 
virtual StepaddNewStep (int step)
 Adds a new step of the same type than the field. More...
 
BooleanStepaddStep (int step)
 Adds a new step. More...
 
BooleanStepaddStep (int step, int stamp)
 Adds a new step. More...
 
BooleanStepgetStep (int index)
 Gets the step of given index. More...
 

the name of the field.

Creates a Field of the given type.

Parameters
typethe type of the field to create.
dimensionthe dimension.
nbElementsthe number of geometrical elements.
nbComponentsthe number of components.
Returns
the created field.
const std::string getName () const
 Gets the name of the Field. More...
 
void setName (const std::string &name)
 Sets the name of the Field. More...
 
XAO::Dimension getDimension () const
 Gets the Dimension of the Field. More...
 
int countElements () const
 Gets the number of elements of each step. More...
 
int countComponents () const
 Gets the number of components. More...
 
int countValues () const
 Gets the number of values for each step. More...
 
int countSteps () const
 Gets the number of the steps. More...
 
const std::string getComponentName (int index)
 Gets the name of a component. More...
 
void setComponentName (int componentIndex, const std::string &name)
 Sets the name of a component. More...
 
void setComponentsNames (const std::vector< std::string > &names)
 Sets the name of the components. More...
 
bool removeStep (Step *step)
 Remove a step. More...
 
bool hasStep (int step)
 Verifies if the field has a step with the given step number. More...
 
stepIterator begin ()
 Returns the first step. More...
 
stepIterator end ()
 Returns the last step. More...
 
std::string m_name
 The name of the Field. More...
 
XAO::Dimension m_dimension
 The dimension of the Field. More...
 
int m_nbComponents
 The number of components. More...
 
std::vector< std::string > m_components
 The components of the field. More...
 
int m_nbElements
 The number of elements. More...
 
std::vector< Step * > m_steps
 The list of steps. More...
 
static FieldcreateField (XAO::Type type, XAO::Dimension dimension, int nbElements, int nbComponents, const std::string &name=std::string(""))
 
void checkComponent (int component)
 
void checkStepIndex (int step)
 

Detailed Description

Represents a field with boolean values.

Constructor & Destructor Documentation

◆ BooleanField()

BooleanField::BooleanField ( XAO::Dimension  dimension,
int  nbElements,
int  nbComponents,
const std::string &  name 
)

Constructor.

Parameters
dimensionthe dimension of the field.
nbElementsthe number of elements.
nbComponentsthe number of components.
namethe name of the field.

Member Function Documentation

◆ getType()

virtual XAO::Type XAO::BooleanField::getType ( )
inlinevirtual

Gets the Type of the field.

Returns
the Type of the field.

Implements XAO::Field.

◆ addNewStep()

Step * BooleanField::addNewStep ( int  number)
virtual

Adds a new step of the same type than the field.

Parameters
numberthe numer of the step.
Returns
the new create step.

Implements XAO::Field.

◆ addStep() [1/2]

BooleanStep * BooleanField::addStep ( int  step)

Adds a new step.

Parameters
stepthe number of the step.
Returns
the newly created step.

◆ addStep() [2/2]

BooleanStep * BooleanField::addStep ( int  step,
int  stamp 
)

Adds a new step.

Parameters
stepthe number of the step.
stampthe stamp of the step.
Returns
the newly created step.

◆ getStep()

BooleanStep * BooleanField::getStep ( int  index)

Gets the step of given index.

Parameters
indexthe index.
Returns
the step for the given index.

◆ getName()

const std::string XAO::Field::getName ( ) const
inlineinherited

Gets the name of the Field.

Returns
the name of the Field.

◆ setName()

void XAO::Field::setName ( const std::string &  name)
inlineinherited

Sets the name of the Field.

Parameters
namethe name to set.

◆ getDimension()

XAO::Dimension XAO::Field::getDimension ( ) const
inlineinherited

Gets the Dimension of the Field.

Returns
the Dimension of the Field.

◆ countElements()

int XAO::Field::countElements ( ) const
inlineinherited

Gets the number of elements of each step.

Returns
the number of elements of each step.

◆ countComponents()

int XAO::Field::countComponents ( ) const
inlineinherited

Gets the number of components.

Returns
the number of components.

◆ countValues()

int XAO::Field::countValues ( ) const
inlineinherited

Gets the number of values for each step.

Returns
the number of values for each step.

◆ countSteps()

int XAO::Field::countSteps ( ) const
inlineinherited

Gets the number of the steps.

Returns
the number of steps.

◆ getComponentName()

const std::string Field::getComponentName ( int  index)
inherited

Gets the name of a component.

Parameters
indexthe index of the component to get.
Returns
the name of the component for the given index.

◆ setComponentName()

void Field::setComponentName ( int  componentIndex,
const std::string &  name 
)
inherited

Sets the name of a component.

Parameters
componentIndexthe index of the component to set.
namethe name to set.

◆ setComponentsNames()

void Field::setComponentsNames ( const std::vector< std::string > &  names)
inherited

Sets the name of the components.

Parameters
namesthe names to set.

◆ removeStep()

bool Field::removeStep ( Step step)
inherited

Remove a step.

Parameters
stepthe step to remove.
Returns
true if the step has been removed, false otherwise.

◆ hasStep()

bool Field::hasStep ( int  step)
inherited

Verifies if the field has a step with the given step number.

Parameters
stepthe step number.
Returns
true if the field has a step for the given number.

◆ begin()

stepIterator XAO::Field::begin ( )
inlineinherited

Returns the first step.

Returns
an iterator on the first step.

◆ end()

stepIterator XAO::Field::end ( )
inlineinherited

Returns the last step.

Returns
an iterator on the last step.

Field Documentation

◆ m_name

std::string XAO::Field::m_name
protectedinherited

The name of the Field.

◆ m_dimension

XAO::Dimension XAO::Field::m_dimension
protectedinherited

The dimension of the Field.

◆ m_nbComponents

int XAO::Field::m_nbComponents
protectedinherited

The number of components.

◆ m_components

std::vector<std::string> XAO::Field::m_components
protectedinherited

The components of the field.

◆ m_nbElements

int XAO::Field::m_nbElements
protectedinherited

The number of elements.

◆ m_steps

std::vector<Step*> XAO::Field::m_steps
protectedinherited

The list of steps.