Choreonoid  1.8
Public Types | Public Member Functions | Protected Member Functions | Friends | List of all members
cnoid::CoordinateFrameList Class Reference

#include <CoordinateFrameList.h>

Inheritance diagram for cnoid::CoordinateFrameList:
cnoid::ClonableReferenced cnoid::Referenced

Public Types

enum  FrameType { Base, Offset }
 

Public Member Functions

 CoordinateFrameList ()
 
 CoordinateFrameList (const CoordinateFrameList &org)
 
 ~CoordinateFrameList ()
 
CoordinateFrameList & operator= (const CoordinateFrameList &rhs)
 
void setFrameType (int type)
 
int frameType () const
 
bool isForBaseFrames () const
 
bool isForOffsetFrames () const
 
void setFirstElementAsDefaultFrame (bool on=true)
 
bool hasFirstElementAsDefaultFrame () const
 
bool isDefaultFrameId (const GeneralId &id) const
 
void clear ()
 
int numFrames () const
 
CoordinateFrame * frameAt (int index) const
 
CoordinateFrame * findFrame (const GeneralId &id) const
 
int indexOf (CoordinateFrame *frame) const
 
bool insert (int index, CoordinateFrame *frame)
 
bool append (CoordinateFrame *frame)
 
void removeAt (int index)
 
bool remove (CoordinateFrame *frame)
 
SignalProxy< void(int index)> sigFrameAdded ()
 
SignalProxy< void(int index, CoordinateFrame *frame)> sigFrameRemoved ()
 
SignalProxy< void(int index, int flags)> sigFrameUpdated ()
 
bool resetId (CoordinateFrame *frame, const GeneralId &newId)
 
void resetIdCounter (int id=0)
 
GeneralId createNextId (int prevId=-1)
 
bool read (const Mapping &archive)
 
void write (Mapping &archive) const
 
void writeHeader (Mapping &archive) const
 
void writeFrames (Mapping &archive) const
 
- Public Member Functions inherited from cnoid::Referenced
virtual ~Referenced ()
 

Protected Member Functions

virtual Referenced * doClone (CloneMap *cloneMap) const override
 
- Protected Member Functions inherited from cnoid::Referenced
 Referenced ()
 
 Referenced (const Referenced &)
 
int refCount () const
 

Friends

class CoordinateFrame
 

Member Enumeration Documentation

◆ FrameType

Enumerator
Base 
Offset 

Constructor & Destructor Documentation

◆ CoordinateFrameList() [1/2]

CoordinateFrameList::CoordinateFrameList ( )

◆ CoordinateFrameList() [2/2]

CoordinateFrameList::CoordinateFrameList ( const CoordinateFrameList &  org)

◆ ~CoordinateFrameList()

CoordinateFrameList::~CoordinateFrameList ( )

Member Function Documentation

◆ append()

bool CoordinateFrameList::append ( CoordinateFrame *  frame)

◆ clear()

void CoordinateFrameList::clear ( )

Keep the default frame if it exists

◆ createNextId()

GeneralId CoordinateFrameList::createNextId ( int  prevId = -1)

◆ doClone()

Referenced * CoordinateFrameList::doClone ( CloneMap *  cloneMap) const
overrideprotectedvirtual

◆ findFrame()

CoordinateFrame * CoordinateFrameList::findFrame ( const GeneralId &  id) const

◆ frameAt()

CoordinateFrame * CoordinateFrameList::frameAt ( int  index) const

◆ frameType()

int cnoid::CoordinateFrameList::frameType ( ) const
inline

◆ hasFirstElementAsDefaultFrame()

bool cnoid::CoordinateFrameList::hasFirstElementAsDefaultFrame ( ) const
inline

◆ indexOf()

int CoordinateFrameList::indexOf ( CoordinateFrame *  frame) const

◆ insert()

bool CoordinateFrameList::insert ( int  index,
CoordinateFrame *  frame 
)

◆ isDefaultFrameId()

bool CoordinateFrameList::isDefaultFrameId ( const GeneralId &  id) const

◆ isForBaseFrames()

bool cnoid::CoordinateFrameList::isForBaseFrames ( ) const
inline

◆ isForOffsetFrames()

bool cnoid::CoordinateFrameList::isForOffsetFrames ( ) const
inline

◆ numFrames()

int CoordinateFrameList::numFrames ( ) const

◆ operator=()

CoordinateFrameList & CoordinateFrameList::operator= ( const CoordinateFrameList &  rhs)

◆ read()

bool CoordinateFrameList::read ( const Mapping &  archive)

◆ remove()

bool CoordinateFrameList::remove ( CoordinateFrame *  frame)

◆ removeAt()

void CoordinateFrameList::removeAt ( int  index)

◆ resetId()

bool CoordinateFrameList::resetId ( CoordinateFrame *  frame,
const GeneralId &  newId 
)
Returns
true if the id is successfully changed. false if the id is not changed because the id is same as the previous id or anther coordinate frame with the same id exists.

◆ resetIdCounter()

void CoordinateFrameList::resetIdCounter ( int  id = 0)

Reset the internal id counter used by the createNextId function.

◆ setFirstElementAsDefaultFrame()

void CoordinateFrameList::setFirstElementAsDefaultFrame ( bool  on = true)

This function set the flag to treat the first element as a special element called default frame. In general, the default frame corresponds to the origin frame, and it is always kept even if the clear function is executed. In addition, the default frame is not stored to the archive, and it is forcibly restored by the system.

◆ setFrameType()

void cnoid::CoordinateFrameList::setFrameType ( int  type)
inline

◆ sigFrameAdded()

SignalProxy< void(int index)> CoordinateFrameList::sigFrameAdded ( )

◆ sigFrameRemoved()

SignalProxy< void(int index, CoordinateFrame *frame)> CoordinateFrameList::sigFrameRemoved ( )

◆ sigFrameUpdated()

SignalProxy< void(int index, int flags)> CoordinateFrameList::sigFrameUpdated ( )

◆ write()

void CoordinateFrameList::write ( Mapping &  archive) const

◆ writeFrames()

void CoordinateFrameList::writeFrames ( Mapping &  archive) const

◆ writeHeader()

void CoordinateFrameList::writeHeader ( Mapping &  archive) const

Friends And Related Function Documentation

◆ CoordinateFrame

friend class CoordinateFrame
friend

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