- Main Page
- Namespaces
- Classes
- Files
- Related Pages

- Alphabetical List
- Class List
- Class Hierarchy
- Class Members

# Mers::Models::CCA::CCAState Class Reference

`#include <CCAState.h>`

Inheritance diagram for Mers::Models::CCA::CCAState:

[legend]
Collaboration diagram for Mers::Models::CCA::CCAState:

[legend]
List of all members.

## Public Types
enum | StateType { NOMINAL, FAILURE, UNKNOWN }
## Public Member Functions
| CCAState ()
| CCAState (const CCAAutomaton &_automaton, const CCAValue &_value)
| CCAState (const CCAState &other)
| ~CCAState ()
bool | set_automaton_p (const CCAAutomaton &_automaton)
const CCAAutomaton * | automaton_p () const
const CCAAutomata * | ccAutomata_p () const
const CCAModel * | model_p () const
char const * | name () const
char const * | getName () const
const CCAValue * | value_p () const
const CCAValue * | getValue () const
bool | set_type (const StateType new_type)
StateType | type () const
StateType | getStateType () const
bool | set_constraint (const CCASentence &new_constraint)
const CCASentence * | constraint_p () const
CCASentence * | constraint_p ()
void | setUID (unsigned int newUID)
unsigned int | getUID () const
CCATransitions::const_iterator | insert_in_transition (CCATransition *_transition)
bool | clear_in_transitionPtrs ()
const CCATransitions * | in_transitionPtrs_p () const
CCATransitions::const_iterator | insert_out_transition (CCATransition *_transition)
bool | clear_out_transitionPtrs ()
const CCATransitions * | out_transitionPtrs_p () const
void | print (std::ostream &out) const
const CCAState & | operator= (const CCAState &other)
bool | operator== (const CCAState &other) const
bool | operator!= (const CCAState &other) const
## Static Public Member Functions
static char const * | stateTypeToString (StateType type)
static int | stringToStateType (char const *str, StateType &type)

## Detailed Description

A CCAState Class.

Author:
  Seung H. Chung

Definition at line 43 of file CCAState.h.

## Member Enumeration Documentation

enum Mers::Models::CCA::CCAState::StateType

The Enumerated type that defines the type of state.
Note:: You must update stateTypeToString and stringToStateType if you add a new type here.

Definition at line 53 of file CCAState.h.

## Member Function Documentation

char const * CCAState::stateTypeToString | ( | StateType | type | ) | `[static]`

Returns the string equivalent to the StateType.

Parameters:

  | type | the enumerated type being converted into a string.

Returns:
  the character string equivalent representation of the enumerated type, or an error string if none exists.

Definition at line 71 of file CCAState.cpp.

Referenced by print(), and Mers::Models::CCA::CCAModel::set_state_type().

int CCAState::stringToStateType | ( | char const * | str,
|  | StateType & | type |
| ) |  |  | `[static]`

Returns the StateType equivalent to the string.

Parameters:

  | str | the string being converted into a StateType.
  | type | the enumerated type that the string represents is returned here.

Returns:
  0 on success or a positive value if the string did not represent a state type.

Definition at line 87 of file CCAState.cpp.

void CCAState::setUID | ( | unsigned int | newUID | ) |

Sets the UID of this automaton, which is also it's index in its parent CCAAutomata.

Parameters:

  | newUID | the new UID of this automaton

Definition at line 199 of file CCAState.cpp.

Referenced by Mers::Models::CCA::CCAStates::pushBack().

unsigned int CCAState::getUID | ( |  | ) | const

Returns the unique identifier of this automaton.

Definition at line 206 of file CCAState.cpp.

void CCAState::print | ( | std::ostream & | out | ) | const`[virtual]`

Prints this CCAState object to the specified stream.

Parameters:

  | out | the ostream to print this object information to

Implements Mers::Utils::Lang::BaseModelObject.

Definition at line 257 of file CCAState.cpp.

References constraint_p(), name(), stateTypeToString(), and type().

Here is the call graph for this function:

The documentation for this class was generated from the following files:

- /Users/fpy/titan-1-5-MBARI/Mers/Models/CCA/CCAState.h
- /Users/fpy/titan-1-5-MBARI/Mers/Models/CCA/CCAState.cpp