|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.deltava.beans.navdata.NavigationDataMap
public class NavigationDataMap
A "map-like" class to support multiple navigation data objects with the same code, and return back a single bean based on distance from an arbitrary point.
| Constructor Summary | |
|---|---|
NavigationDataMap()
Creates an empty NavigationDataMap bean. |
|
NavigationDataMap(Collection<NavigationDataBean> entries)
Creates a pre-populaed NavigationDataMap bean. |
|
| Method Summary | |
|---|---|
void |
add(NavigationDataBean nd)
Adds a navigation aid to the map. |
void |
addAll(Collection<NavigationDataBean> beans)
Adds a number of navigation aids to the map. |
Object |
cacheKey()
Returns this bean's cache key. |
boolean |
contains(String code)
Returns if the Map contains at least one Navigation Data bean with a particular code. |
void |
filter(Collection<Integer> types)
Filters out navigation aids based on their type. |
void |
filter(int navaidType)
Filters out all navigation aids not of a particular type. |
NavigationDataBean |
get(String code)
Returns a Navigation Aid with a given code. |
NavigationDataBean |
get(String code,
GeoLocation loc)
Returns a Navigation Aid with a given code. |
Collection<NavigationDataBean> |
getAll()
Returns all navigation aid beans contained within this object. |
Set<NavigationDataBean> |
getEntries(String code)
Returns all entries with a given code. |
boolean |
isEmpty()
Returns whether the map is empty. |
void |
setCacheKey(Object key)
Sets this bean's cache key. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public NavigationDataMap()
public NavigationDataMap(Collection<NavigationDataBean> entries)
entries - the navigation aid beans to add| Method Detail |
|---|
public void add(NavigationDataBean nd)
nd - the navigation aid bean
NullPointerException - if nd is nullpublic void addAll(Collection<NavigationDataBean> beans)
beans - a Collection of NavigationDataBeanspublic boolean contains(String code)
code - the code
public Set<NavigationDataBean> getEntries(String code)
code - the navigation aid code
public NavigationDataBean get(String code)
code - the navigation aid code
get(String, GeoLocation)
public NavigationDataBean get(String code,
GeoLocation loc)
code - the navigation aid codeloc - the reference location
get(String)public Collection<NavigationDataBean> getAll()
public boolean isEmpty()
public void filter(Collection<Integer> types)
types - a Collection of Integers with navigation aid type codesNavigationDataBean.getType(),
filter(int)public void filter(int navaidType)
navaidType - the navigation aid type code to retainfilter(Collection),
NavigationDataBean.getType()public void setCacheKey(Object key)
key - the cache keypublic Object cacheKey()
cacheKey in interface Cacheable
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||