|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
A layer to be rendered on a device. A layer is an aggregation of both a
FeatureCollection
, a Style
and, optionally, a Query
Method Summary | |
void |
addMapLayerListener(MapLayerListener listener)
Add a listener to notify when a layer property changes. |
FeatureSource |
getFeatureSource()
Get the feature collection for this layer. |
Query |
getQuery()
Returns the definition query (filter) for this layer. |
Style |
getStyle()
Get the style for this layer. |
java.lang.String |
getTitle()
Get the title of this layer. |
boolean |
isVisible()
Determine whether this layer is visible on a map pane or whether the layer is hidden. |
void |
removeMapLayerListener(MapLayerListener listener)
Removes a listener from the listener list for this layer. |
void |
setQuery(Query query)
Sets a definition query for the layer wich acts as a filter for the features that the layer will draw. |
void |
setStyle(Style style)
Sets the style for this layer. |
void |
setTitle(java.lang.String title)
Set the title of this layer. |
void |
setVisible(boolean visible)
Specify whether this layer is visible on a map pane or whether the layer is hidden. |
Method Detail |
public FeatureSource getFeatureSource()
public Style getStyle()
public void setStyle(Style style)
style
- The new stylepublic java.lang.String getTitle()
public void setTitle(java.lang.String title)
LayerEvent
is fired if the new
title is different from the previous one.
title
- The title of this layer.public boolean isVisible()
true
if the layer is visible, or false
if the layer is hidden.public void setVisible(boolean visible)
LayerEvent
is fired if the visibility changed.
visible
- Show the layer if true
, or hide the layer if
false
public Query getQuery()
Query.ALL
is returned.
public void setQuery(Query query)
A consumer must ensure that this query is used in combination with the bounding box filter generated on each map interaction to limit the number of features returned to those that complains both the definition query and relies inside the area of interest.
IMPORTANT: only include attribute names in the query if you want them to be ALWAYS returned. It is desirable to not include attributes at all but let the layer user (a renderer?) to decide wich attributes are actually needed to perform its requiered operation.
query
- public void addMapLayerListener(MapLayerListener listener)
listener
- The listener to add to the listener list.public void removeMapLayerListener(MapLayerListener listener)
listener
- The listener to remove from the listener list.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |