cad.simcad.objectserver.spec.pathfinding
Interface PathUser

All Known Implementing Classes:
IDPathUser, MyUnit

public interface PathUser

Interface for a single entity able to use a Path. Any object wishing to ask the service of a PathFinder must implement this interface

Version:
1.0
Author:
Charles-Philip Bentley

Method Summary
 void firePathComputed(PathPlaceSet pps)
          Notice the PathUser that a Path has been computed for him.
 PathPlace getCurrentPathPlace()
          Return the current PathPlace the PathUser is on
 double getDeformFactor()
          Returns the deform factor of the Path user.
 int getId()
          Return the id of the PathUser.
 double getMaxSteepNessRatio()
          Return the maximum slope ratio the PathUser can walk on.
 java.lang.String getName()
          Return the name of the PathUser.
 

Method Detail

getDeformFactor

public double getDeformFactor()
Returns the deform factor of the Path user. The Deform factor is a ratio. 0 means the PathUser shrink completely to pass through holes infinitely small 1 means the PathUser is unabled to shrink 0.5 means the PathUser can shrink to half its size. Usually, most mechanical objects will have a deform factor of 1. While human can usually shrink a little to go through narrow pathways

Pre:
-
Returns:
double value
Post:
PathUser's deform factor

getId

public int getId()
Return the id of the PathUser.

Pre:
-
Returns:
int value
Post:
PathUser's unique id.

getMaxSteepNessRatio

public double getMaxSteepNessRatio()
Return the maximum slope ratio the PathUser can walk on.

Pre:
-
Returns:
double value
Post:
PathUser's Max slope ratio

firePathComputed

public void firePathComputed(PathPlaceSet pps)
Notice the PathUser that a Path has been computed for him.

Parameters:
pps - A PathPlaceSet.
Pre:
pps.getPathUser().equals(this) The PathUser of the PathPlaceSet is the same object as this one

getName

public java.lang.String getName()
Return the name of the PathUser.

Pre:
-
Returns:
int value
Post:
PathUser's name.

getCurrentPathPlace

public PathPlace getCurrentPathPlace()
Return the current PathPlace the PathUser is on

Pre:
-
Returns:
The current PathPlace, null if the PathUser has no PathPlace set already
Post:
the PathPlace of the PathUser is returned

Logo

With the help of www.sourceforge.net and www.info.ucl.ac.be