RigsofRods
Soft-body Physics Simulation
Public Member Functions | Private Attributes
RigDef::Node::Ref Class Reference

Legacy parser resolved references on-the-fly and the condition to check named nodes was "are there any named nodes defined at this point?" The new parser defers node resolution, so every ref. More...

#include <RigDef_Node.h>

Public Member Functions

 BITMASK_PROPERTY_GET (m_flags, 1, IMPORT_STATE_IS_VALID, GetImportState_IsValid)
 
 BITMASK_PROPERTY_GET (m_flags, 2, IMPORT_STATE_MUST_CHECK_NAMED_FIRST, GetImportState_MustCheckNamedFirst)
 
 BITMASK_PROPERTY_GET (m_flags, 3, IMPORT_STATE_IS_RESOLVED_NAMED, GetImportState_IsResolvedNamed)
 
 BITMASK_PROPERTY_GET (m_flags, 4, IMPORT_STATE_IS_RESOLVED_NUMBERED, GetImportState_IsResolvedNumbered)
 
 BITMASK_PROPERTY_GET (m_flags, 5, REGULAR_STATE_IS_VALID, GetRegularState_IsValid)
 
 BITMASK_PROPERTY_GET (m_flags, 6, REGULAR_STATE_IS_NAMED, GetRegularState_IsNamed)
 
 BITMASK_PROPERTY_GET (m_flags, 7, REGULAR_STATE_IS_NUMBERED, GetRegularState_IsNumbered)
 
 Ref (std::string const &id_str, unsigned int id_num, unsigned flags, unsigned line_number_defined)
 
 Ref ()
 
const std::string & Str () const
 
unsigned int Num () const
 
bool Compare (Ref const &rhs) const
 
bool operator== (Ref const &rhs) const
 
bool operator!= (Ref const &rhs) const
 
bool IsValidAnyState () const
 
unsigned GetLineNumber () const
 
void Invalidate ()
 
std::string ToString () const
 

Private Attributes

std::string m_id
 
unsigned int m_id_as_number
 
unsigned int m_flags
 
unsigned int m_line_number
 

Detailed Description

Legacy parser resolved references on-the-fly and the condition to check named nodes was "are there any named nodes defined at this point?" The new parser defers node resolution, so every ref.

must keep track whether named nodes were already defined at that point.

Definition at line 77 of file RigDef_Node.h.

Constructor & Destructor Documentation

◆ Ref() [1/2]

Node::Ref::Ref ( std::string const &  id_str,
unsigned int  id_num,
unsigned  flags,
unsigned  line_number_defined 
)

Definition at line 79 of file RigDef_Node.cpp.

◆ Ref() [2/2]

Node::Ref::Ref ( )

Definition at line 88 of file RigDef_Node.cpp.

Member Function Documentation

◆ BITMASK_PROPERTY_GET() [1/7]

RigDef::Node::Ref::BITMASK_PROPERTY_GET ( m_flags  ,
,
IMPORT_STATE_IS_VALID  ,
GetImportState_IsValid   
)

◆ BITMASK_PROPERTY_GET() [2/7]

RigDef::Node::Ref::BITMASK_PROPERTY_GET ( m_flags  ,
,
IMPORT_STATE_MUST_CHECK_NAMED_FIRST  ,
GetImportState_MustCheckNamedFirst   
)

◆ BITMASK_PROPERTY_GET() [3/7]

RigDef::Node::Ref::BITMASK_PROPERTY_GET ( m_flags  ,
,
IMPORT_STATE_IS_RESOLVED_NAMED  ,
GetImportState_IsResolvedNamed   
)

◆ BITMASK_PROPERTY_GET() [4/7]

RigDef::Node::Ref::BITMASK_PROPERTY_GET ( m_flags  ,
,
IMPORT_STATE_IS_RESOLVED_NUMBERED  ,
GetImportState_IsResolvedNumbered   
)

◆ BITMASK_PROPERTY_GET() [5/7]

RigDef::Node::Ref::BITMASK_PROPERTY_GET ( m_flags  ,
,
REGULAR_STATE_IS_VALID  ,
GetRegularState_IsValid   
)

◆ BITMASK_PROPERTY_GET() [6/7]

RigDef::Node::Ref::BITMASK_PROPERTY_GET ( m_flags  ,
,
REGULAR_STATE_IS_NAMED  ,
GetRegularState_IsNamed   
)

◆ BITMASK_PROPERTY_GET() [7/7]

RigDef::Node::Ref::BITMASK_PROPERTY_GET ( m_flags  ,
,
REGULAR_STATE_IS_NUMBERED  ,
GetRegularState_IsNumbered   
)

◆ Compare()

bool RigDef::Node::Ref::Compare ( Ref const &  rhs) const
inline

Definition at line 97 of file RigDef_Node.h.

+ Here is the caller graph for this function:

◆ GetLineNumber()

unsigned RigDef::Node::Ref::GetLineNumber ( ) const
inline

Definition at line 102 of file RigDef_Node.h.

+ Here is the caller graph for this function:

◆ Invalidate()

void Node::Ref::Invalidate ( )

Definition at line 95 of file RigDef_Node.cpp.

◆ IsValidAnyState()

bool RigDef::Node::Ref::IsValidAnyState ( ) const
inline

Definition at line 101 of file RigDef_Node.h.

+ Here is the caller graph for this function:

◆ Num()

unsigned int RigDef::Node::Ref::Num ( ) const
inline

Definition at line 95 of file RigDef_Node.h.

+ Here is the caller graph for this function:

◆ operator!=()

bool RigDef::Node::Ref::operator!= ( Ref const &  rhs) const
inline

Definition at line 99 of file RigDef_Node.h.

+ Here is the call graph for this function:

◆ operator==()

bool RigDef::Node::Ref::operator== ( Ref const &  rhs) const
inline

Definition at line 98 of file RigDef_Node.h.

+ Here is the call graph for this function:

◆ Str()

const std::string& RigDef::Node::Ref::Str ( ) const
inline

Definition at line 94 of file RigDef_Node.h.

+ Here is the caller graph for this function:

◆ ToString()

std::string Node::Ref::ToString ( ) const

Definition at line 103 of file RigDef_Node.cpp.

+ Here is the caller graph for this function:

Field Documentation

◆ m_flags

unsigned int RigDef::Node::Ref::m_flags
private

Definition at line 110 of file RigDef_Node.h.

◆ m_id

std::string RigDef::Node::Ref::m_id
private

Definition at line 108 of file RigDef_Node.h.

◆ m_id_as_number

unsigned int RigDef::Node::Ref::m_id_as_number
private

Definition at line 109 of file RigDef_Node.h.

◆ m_line_number

unsigned int RigDef::Node::Ref::m_line_number
private

Definition at line 111 of file RigDef_Node.h.


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