Go to the documentation of this file.
7 #ifndef CNOID_BODY_LINK_TRAVERSE_H
8 #define CNOID_BODY_LINK_TRAVERSE_H
11 #include "exportdecl.h"
31 virtual void find(
Link* root,
bool doUpward =
false,
bool doDownward =
true);
33 void append(
Link* link,
bool isDownward =
true);
35 bool remove(
Link* link);
38 Link* prependRootAdjacentLinkToward(
Link* link);
41 return static_cast<int>(links_.size());
45 return links_.empty();
53 return (links_.empty() ?
nullptr : links_.front());
60 Link* operator[] (
int index)
const {
64 const std::vector<Link*>&
links()
const {
return links_; }
80 return (index >= numUpwardConnections);
83 void calcForwardKinematics(
bool calcVelocity =
false,
bool calcAcceleration =
false)
const;
90 void traverse(
Link* link,
bool doUpward,
bool doDownward,
bool isUpward,
Link* prev);
91 Link* findRootAdjacentLink(
Link* link,
Link* prev,
Link* root,
bool& isUpward);
iterator end()
Definition: LinkTraverse.h:70
const_iterator begin() const
Definition: LinkTraverse.h:71
std::vector< Link * > container
Definition: LinkTraverse.h:20
int numLinks() const
Definition: LinkTraverse.h:40
Link * link(int index) const
Definition: LinkTraverse.h:56
iterator begin()
Definition: LinkTraverse.h:69
Link * rootLink() const
Definition: LinkTraverse.h:52
bool empty() const
Definition: LinkTraverse.h:44
const_iterator end() const
Definition: LinkTraverse.h:72
Definition: AbstractSceneLoader.h:11
Definition: LinkTraverse.h:17
const std::vector< Link * > & links() const
Definition: LinkTraverse.h:64
int numUpwardConnections
Definition: LinkTraverse.h:87
std::vector< Link * > links_
Definition: LinkTraverse.h:86
bool isDownward(int index) const
Definition: LinkTraverse.h:79
container::const_iterator const_iterator
Definition: LinkTraverse.h:67
std::size_t size() const
Definition: LinkTraverse.h:48
container::iterator iterator
Definition: LinkTraverse.h:66