|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object pacworld.VisiblePackage
public class VisiblePackage
The representation of a package in an agent's percept. This includes the package's id, current location, delivery location, and whether or not it is held by an agent.
Constructor Summary | |
---|---|
VisiblePackage(Package pack)
Create a new percept of a package using the package itself. |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object obj)
Tests if this object is equivalent to another object by comparing the id's of the packages. |
int |
getDestX()
Get the X coordinate of the location to deliver the package. |
int |
getDestY()
Get the Y coordinate of the location to deliver the package. |
int |
getId()
Get the unique integer id for the package. |
int |
getX()
Get the X location of the package. |
int |
getY()
Get the Y location of the package. |
boolean |
isHeld()
Is the package currently held by some agent? |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public VisiblePackage(Package pack)
Method Detail |
---|
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int getDestX()
public int getDestY()
public int getId()
public int getX()
public int getY()
public boolean isHeld()
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |