|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectlejos.robotics.pathfinding.NodePathFinder
public class NodePathFinder
This path finder class uses one of the common search algorithms (e.g. A*) and a navigation mesh (e.g. grid) and uses them to find a path around map geometry.
Constructor Summary | |
---|---|
NodePathFinder(SearchAlgorithm alg,
NavigationMesh mesh)
Instantiates a NodePathFinder object using a specified algorithm. |
Method Summary | |
---|---|
void |
addListener(WayPointListener wpl)
|
Collection<WayPoint> |
findRoute(Pose start,
WayPoint goal)
|
void |
setNavMesh(NavigationMesh mesh)
Method for changing the navigation mesh after this has been instantiated. |
void |
setSearchAlgorithm(SearchAlgorithm alg)
Method for changing the search algorithm after this has been instantiated. |
void |
startPathFinding(Pose start,
WayPoint end)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public NodePathFinder(SearchAlgorithm alg, NavigationMesh mesh)
alg
- The search algorithm.mesh
- The navigation mesh is a set of nodes in various configurations (e.g. grid).Method Detail |
---|
public void setNavMesh(NavigationMesh mesh)
mesh
- public void setSearchAlgorithm(SearchAlgorithm alg)
alg
- public void addListener(WayPointListener wpl)
addListener
in interface PathFinder
public Collection<WayPoint> findRoute(Pose start, WayPoint goal) throws DestinationUnreachableException
findRoute
in interface PathFinder
DestinationUnreachableException
public void startPathFinding(Pose start, WayPoint end)
startPathFinding
in interface PathFinder
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |