|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.util.Observable | +--mil.af.afit.router.Site
A site is a location to visit. It may have a time window or time wall associated with it. It may have a specific requirement for what kind of vehicle needs to service it.
SiteList
, Serialized FormConstructor Summary | |
Site()
Constructs a site with default values. |
|
Site(Site copyThis)
Constructs a site identical to copyThis. |
|
Site(java.lang.String name,
double latitude,
double longitude)
Constructs a site with specified name, latitude, and longitude. |
|
Site(java.lang.String name,
double latitude,
double longitude,
int priority)
Constructs a site with specified name, latitude, longitude, and priority. |
Method Summary | |
int |
getEarliestArrivalTime()
Returns the beginning of time window for the site. |
int |
getEarliestRestrictedTime()
Returns the beginning of time wall for the site. |
int |
getID()
Returns the id of the site. |
int |
getLatestDepartureTime()
Returns the ending of time window for the site. |
int |
getLatestRestrictedTime()
Returns the ending of time wall for the site. |
double |
getLatitude()
Returns the latitude of the site. |
double |
getLongitude()
Returns the longitude of the site. |
java.lang.String |
getName()
Returns the name of the site. |
int |
getPriority()
Returns the priority of the site. |
java.lang.String |
getRequirementType()
Returns the requirement type of the site. |
int |
getServiceTime()
Returns the service time (in minutes) for the site. |
boolean |
isEnabled()
Returns whether or not the site is enabled. |
int |
isEnabledAsNumber()
Returns whether or not the site is enabled, 1 for true, 2 for false. |
static void |
setDefaultPriority(int priority)
Set default priority for sites (a static variable). |
static void |
setDefaultServiceTime(int time)
Set default service time for sites (a static variable). |
void |
setEarliestArrivalTime(int time)
Sets the beginning of the time window for the site. |
void |
setEarliestRestrictedTime(int time)
Sets the beginning of the time wall for the site. |
void |
setEnabled(boolean state)
Sets whether or not the site is enabled. |
void |
setLatestDepartureTime(int time)
Sets the ending of the time window for the site. |
void |
setLatestRestrictedTime(int time)
Sets the ending of the time wall for the site. |
void |
setLatitude(double latitude)
Sets the latitude for the site. |
void |
setLongitude(double longitude)
Sets the longitude for the site. |
void |
setName(java.lang.String name)
Sets the name for the site. |
void |
setPriority(int priority)
Sets the priority for the site. |
void |
setRequirementType(java.lang.String type)
Sets the requirement type for the site. |
void |
setServiceTime(int minutes)
Sets the service time (in minutes) for the site. |
java.lang.String |
toString()
|
Methods inherited from class java.util.Observable |
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public Site()
public Site(java.lang.String name, double latitude, double longitude)
name
- site namelatitude
- site's latitudelongitude
- site's longitudepublic Site(java.lang.String name, double latitude, double longitude, int priority)
name
- site namelatitude
- site's latitudelongitude
- site's longitudepriority
- site's prioritypublic Site(Site copyThis)
copyThis
- site to copyMethod Detail |
public static final void setDefaultServiceTime(int time)
time
- default service time (in minutes) for new sitespublic static final void setDefaultPriority(int priority)
priority
- default priority for new sitespublic void setName(java.lang.String name)
name
- name of the sitepublic void setEnabled(boolean state)
state
- whether or not the site is enabledpublic void setLatitude(double latitude)
latitude
- the latitude for the sitepublic void setLongitude(double longitude)
longitude
- the longitude for the sitepublic final void setEarliestArrivalTime(int time)
time
- the beginning of the time window for the sitepublic final void setLatestDepartureTime(int time)
time
- the ending of the time window for the sitepublic final void setEarliestRestrictedTime(int time)
time
- the beginning of the wall window for the sitepublic final void setLatestRestrictedTime(int time)
time
- the ending of the wall window for the sitepublic final void setPriority(int priority)
priority
- the priority for the sitepublic final void setRequirementType(java.lang.String type)
type
- the requirement type for the sitepublic final void setServiceTime(int minutes)
minutes
- the service time (in minutes) for the sitepublic final int getServiceTime()
public final boolean isEnabled()
public final int isEnabledAsNumber()
public final int getID()
public java.lang.String getName()
public double getLatitude()
public double getLongitude()
public final int getEarliestArrivalTime()
public final int getLatestDepartureTime()
public final int getEarliestRestrictedTime()
public final int getLatestRestrictedTime()
public final int getPriority()
public final java.lang.String getRequirementType()
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |