|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectNPTLab.CoordSet
public class CoordSet
Class that contains a set of all the location visited wrapped with an univocal ID. CoordWrapper element contains a Coord element and his univoque ID.
Field Summary | |
---|---|
static java.util.Set<CoordWrapper> |
GlobalSet
|
Constructor Summary | |
---|---|
CoordSet()
Set of All the locations |
Method Summary | |
---|---|
static boolean |
addCw(CoordWrapper cw)
Adds a CoordWrapper to the set if not already contained |
static boolean |
contains(CoordWrapper CW)
Checks if the global set already contains a Coord |
static CoordWrapper |
getCw(core.Coord c)
Returns a new CW if the cw is not contained in global set or the CW itself if it's contained, all based on passed coordinates |
static int |
getEntryIdByCoord(core.Coord c)
Gets an Entry ID in the global set by the Coord Passed |
java.lang.String |
toString()
Method for printing |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static java.util.Set<CoordWrapper> GlobalSet
Constructor Detail |
---|
public CoordSet()
Method Detail |
---|
public static boolean contains(CoordWrapper CW)
CW
- The CoordWrapper element that is to be checkd
public static boolean addCw(CoordWrapper cw)
cw
- The CoordWrapper element that has to be added
public static int getEntryIdByCoord(core.Coord c)
c
- Coord element used to get the Entry in the set
public static CoordWrapper getCw(core.Coord c)
c
- Coord element used to create the CW or to return the already existent CW
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 |