LocalGuidance
A library that generates velocity references to follow a path.
navigation_common::Node Class Reference

#include <Node.hpp>

Public Types

typedef std::shared_ptr< NodeNodePtr
 

Public Member Functions

 Node (const PoseStampedPtr &poseStamped)
 
virtual ~Node ()=default
 
void addEdgeStartingHere (const EdgePtr &edge)
 
void addEdgeEndingHere (const EdgePtr &edge)
 
void removeEdgeStartingHere (const EdgePtr &edge)
 
void removeEdgeEndingHere (const EdgePtr &edge)
 
std::vector< EdgePtrgetEdgesStartingHere () const
 
std::vector< EdgePtrgetEdgesEndingHere () const
 
EdgePtr getEdgeGoingToNode (const NodePtr &end) const
 
EdgePtr getEdgeComingFromNode (const NodePtr &start) const
 
bool isUnconnected () const
 
std::vector< NodePtrgetNeighborNodes () const
 
void interpolateOrientation ()
 
NodePtr getDeepCopy () const
 

Public Attributes

PoseStampedPtr poseStamped_
 Underlying pose. More...
 
std::vector< EdgePtredgesStartingHere_
 Edges. More...
 
std::vector< EdgePtredgesEndingHere_
 

Member Typedef Documentation

typedef std::shared_ptr<Node> navigation_common::Node::NodePtr

Constructor & Destructor Documentation

navigation_common::Node::Node ( const PoseStampedPtr poseStamped)
explicit

Constructor.

virtual navigation_common::Node::~Node ( )
virtualdefault

Destructor.

Member Function Documentation

void navigation_common::Node::addEdgeEndingHere ( const EdgePtr edge)

Add an edge which ends at this node.

Parameters
edgeedge to add.
void navigation_common::Node::addEdgeStartingHere ( const EdgePtr edge)

Add an edge which starts at this node.

Parameters
edgeedge to add.
NodePtr navigation_common::Node::getDeepCopy ( ) const

Create a deep copy of this node.

Returns
new node with new stamped pose.
EdgePtr navigation_common::Node::getEdgeComingFromNode ( const NodePtr start) const

Get the edge which starts at another node and comes here.

Parameters
endother node.
Returns
edge.
EdgePtr navigation_common::Node::getEdgeGoingToNode ( const NodePtr end) const

Get the edge which starts here and goes to another node.

Parameters
endother node.
Returns
edge.
std::vector<EdgePtr> navigation_common::Node::getEdgesEndingHere ( ) const

Get edges ending here.

Returns
edges ending here.
std::vector<EdgePtr> navigation_common::Node::getEdgesStartingHere ( ) const

Get edges starting here.

Returns
edges starting here.
std::vector<NodePtr> navigation_common::Node::getNeighborNodes ( ) const

Get the neighbor nodes which are connected to this node with an edge.

Returns
neighbor nodes.
void navigation_common::Node::interpolateOrientation ( )

Change the orientation of this pose in order to match the edges. Only affects the orientation if ignoreOrientation is true if this node has 1 or 2 neighbors.

bool navigation_common::Node::isUnconnected ( ) const

Check if the node is unconnected.

Returns
true if unconnected.
void navigation_common::Node::removeEdgeEndingHere ( const EdgePtr edge)

Remove an edge which ends at this node.

Parameters
edgeedge to remove.
void navigation_common::Node::removeEdgeStartingHere ( const EdgePtr edge)

Remove an edge which starts at this node.

Parameters
edgeedge to remove.

Member Data Documentation

std::vector<EdgePtr> navigation_common::Node::edgesEndingHere_
std::vector<EdgePtr> navigation_common::Node::edgesStartingHere_

Edges.

PoseStampedPtr navigation_common::Node::poseStamped_

Underlying pose.


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