|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.geotools.map.DefaultMapContext
The default implementation of the interface
| Field Summary | |
protected java.lang.String |
abstracts
Holds value of property abstracts. |
protected java.lang.String |
contactInformation
Holds value of property contactInformation. |
protected java.lang.String[] |
keywords
Holds value of property keywords. |
protected MapLayerListener |
layerListener
|
protected javax.swing.event.EventListenerList |
listenerList
Utility field used by event firing mechanism. |
protected java.beans.PropertyChangeSupport |
propertyChangeSupport
Utility field used by bound properties. |
protected java.lang.String |
title
Holds value of property title. |
| Constructor Summary | |
DefaultMapContext()
Creates a default empty map context |
|
DefaultMapContext(MapLayer[] layers)
Creates a map context with the provided layers and title |
|
DefaultMapContext(MapLayer[] layers,
java.lang.String title,
java.lang.String contextAbstract,
java.lang.String contactInformation,
java.lang.String[] keywords)
Creates a map context |
|
| Method Summary | |
void |
addLayer(FeatureCollection collection,
Style style)
Add a new layer and trigger a LayerListEvent. |
void |
addLayer(FeatureSource featureSource,
Style style)
Add a new layer and trigger a LayerListEvent. |
void |
addLayer(org.opengis.coverage.grid.GridCoverage gc,
Style style)
Add a new layer and trigger a LayerListEvent. |
boolean |
addLayer(int index,
MapLayer layer)
Add a new layer if not already present and trigger a LayerListEvent. |
boolean |
addLayer(MapLayer layer)
Add a new layer and trigger a LayerListEvent. |
int |
addLayers(MapLayer[] layers)
Add an array of new layers and trigger a LayerListEvent. |
void |
addMapBoundsListener(MapBoundsListener listener)
Registers MapBoundsListener to receive events. |
void |
addMapLayerListListener(MapLayerListListener listener)
Registers MapLayerListListener to receive events. |
void |
addPropertyChangeListener(java.beans.PropertyChangeListener listener)
Registers PropertyChangeListener to receive events. |
void |
clearLayerList()
DOCUMENT ME! |
java.lang.String |
getAbstract()
Getter for property abstracts. |
com.vividsolutions.jts.geom.Envelope |
getAreaOfInterest()
Gets the current area of interest. |
java.lang.String |
getContactInformation()
Getter for property contactInformation. |
org.opengis.referencing.crs.CoordinateReferenceSystem |
getCoordinateReferenceSystem()
Get the current coordinate system. |
java.lang.String[] |
getKeywords()
Getter for property keywords. |
MapLayer |
getLayer(int index)
Return the requested layer. |
com.vividsolutions.jts.geom.Envelope |
getLayerBounds()
Get the bounding box of all the layers in this MapContext. |
int |
getLayerCount()
Returns the number of layers in this map context |
MapLayer[] |
getLayers()
Return this model's list of layers. |
java.lang.String |
getTitle()
Getter for property title. |
int |
indexOf(MapLayer layer)
Returns the index of the first occurrence of the specified layer, or -1 if this list does not contain this element. |
java.util.Iterator |
iterator()
Returns an iterator over the layers in this context in proper sequence. |
void |
moveLayer(int sourcePosition,
int destPosition)
DOCUMENT ME! |
MapLayer |
removeLayer(int index)
DOCUMENT ME! |
boolean |
removeLayer(MapLayer layer)
Remove a layer and trigger a LayerListEvent. |
void |
removeLayers(MapLayer[] layers)
Remove an array of layers and trigger a LayerListEvent. |
void |
removeMapBoundsListener(MapBoundsListener listener)
Removes MapBoundsListener from the list of listeners. |
void |
removeMapLayerListListener(MapLayerListListener listener)
Removes MapLayerListListener from the list of listeners. |
void |
removePropertyChangeListener(java.beans.PropertyChangeListener listener)
Removes PropertyChangeListener from the list of listeners. |
void |
setAbstract(java.lang.String abstractValue)
Setter for property abstracts. |
void |
setAreaOfInterest(com.vividsolutions.jts.geom.Envelope areaOfInterest)
Set a new area of interest and trigger an BoundingBoxEvent. |
void |
setAreaOfInterest(com.vividsolutions.jts.geom.Envelope areaOfInterest,
org.opengis.referencing.crs.CoordinateReferenceSystem coordinateReferenceSystem)
Set a new area of interest and trigger a BoundingBoxEvent. |
void |
setContactInformation(java.lang.String contactInformation)
Setter for property contactInformation. |
void |
setKeywords(java.lang.String[] keywords)
Setter for property keywords. |
void |
setTitle(java.lang.String title)
Setter for property title. |
void |
transform(java.awt.geom.AffineTransform transform)
Transform the coordinates according to the provided transform. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected javax.swing.event.EventListenerList listenerList
protected MapLayerListener layerListener
protected java.lang.String abstracts
protected java.beans.PropertyChangeSupport propertyChangeSupport
protected java.lang.String contactInformation
protected java.lang.String[] keywords
protected java.lang.String title
| Constructor Detail |
public DefaultMapContext()
public DefaultMapContext(MapLayer[] layers)
layers - DOCUMENT ME!
public DefaultMapContext(MapLayer[] layers,
java.lang.String title,
java.lang.String contextAbstract,
java.lang.String contactInformation,
java.lang.String[] keywords)
layers - DOCUMENT ME!title - DOCUMENT ME!contextAbstract - DOCUMENT ME!contactInformation - DOCUMENT ME!keywords - DOCUMENT ME!| Method Detail |
public boolean addLayer(int index,
MapLayer layer)
LayerListEvent.
addLayer in interface MapContextindex - DOCUMENT ME!layer - Then new layer that has been added.
public boolean addLayer(MapLayer layer)
LayerListEvent.
addLayer in interface MapContextlayer - Then new layer that has been added.
public void addLayer(FeatureSource featureSource,
Style style)
LayerListEvent.
addLayer in interface MapContextfeatureSource - Then new layer that has been added.style - DOCUMENT ME!
public void addLayer(org.opengis.coverage.grid.GridCoverage gc,
Style style)
LayerListEvent.
addLayer in interface MapContextgc - Then new layer that has been added.style - DOCUMENT ME!
public void addLayer(FeatureCollection collection,
Style style)
LayerListEvent.
addLayer in interface MapContextcollection - Then new layer that has been added.style - DOCUMENT ME!public boolean removeLayer(MapLayer layer)
LayerListEvent.
removeLayer in interface MapContextlayer - Then new layer that has been removed.
public MapLayer removeLayer(int index)
removeLayer in interface MapContextindex - DOCUMENT ME!
public int addLayers(MapLayer[] layers)
LayerListEvent.
addLayers in interface MapContextlayers - The new layers that are to be added.
public void removeLayers(MapLayer[] layers)
LayerListEvent.
removeLayers in interface MapContextlayers - The layers that are to be removed.public MapLayer[] getLayers()
getLayers in interface MapContext
public MapLayer getLayer(int index)
throws java.lang.IndexOutOfBoundsException
getLayer in interface MapContextindex - index of layer to return.
java.lang.IndexOutOfBoundsException - if the index is out of rangepublic int indexOf(MapLayer layer)
MapContext
indexOf in interface MapContextMapContext.indexOf(org.geotools.map.MapLayer)public java.util.Iterator iterator()
iterator in interface MapContext
public com.vividsolutions.jts.geom.Envelope getLayerBounds()
throws java.io.IOException
getLayerBounds in interface MapContextjava.io.IOException - DOCUMENT ME!
public void setAreaOfInterest(com.vividsolutions.jts.geom.Envelope areaOfInterest,
org.opengis.referencing.crs.CoordinateReferenceSystem coordinateReferenceSystem)
throws java.lang.IllegalArgumentException
BoundingBoxEvent. Note
that this is the only method to change coordinate system. A
setCoordinateReferenceSystem method is not provided to
ensure this class is not dependant on transform classes.
setAreaOfInterest in interface MapContextareaOfInterest - The new areaOfInterest.coordinateReferenceSystem - The coordinate system being using by
this model.
java.lang.IllegalArgumentException - if an argument is null.
java.lang.NullPointerException - DOCUMENT ME!public void setAreaOfInterest(com.vividsolutions.jts.geom.Envelope areaOfInterest)
BoundingBoxEvent.
setAreaOfInterest in interface MapContextareaOfInterest - The new area of interest.
java.lang.NullPointerException - DOCUMENT ME!public com.vividsolutions.jts.geom.Envelope getAreaOfInterest()
getAreaOfInterest in interface MapContextpublic org.opengis.referencing.crs.CoordinateReferenceSystem getCoordinateReferenceSystem()
getCoordinateReferenceSystem in interface MapContextpublic void transform(java.awt.geom.AffineTransform transform)
transform in interface MapContexttransform - The transform to change area of interest.
public void moveLayer(int sourcePosition,
int destPosition)
moveLayer in interface MapContextsourcePosition - DOCUMENT ME!destPosition - DOCUMENT ME!
java.lang.IndexOutOfBoundsException - DOCUMENT ME!public void clearLayerList()
clearLayerList in interface MapContextpublic int getLayerCount()
getLayerCount in interface MapContextpublic java.lang.String getAbstract()
getAbstract in interface MapContextpublic void setAbstract(java.lang.String abstractValue)
setAbstract in interface MapContextabstractValue - New value of property abstracts.
java.lang.NullPointerException - DOCUMENT ME!public java.lang.String getContactInformation()
getContactInformation in interface MapContextpublic void setContactInformation(java.lang.String contactInformation)
setContactInformation in interface MapContextcontactInformation - New value of property contactInformation.
java.lang.NullPointerException - DOCUMENT ME!public java.lang.String[] getKeywords()
getKeywords in interface MapContextpublic void setKeywords(java.lang.String[] keywords)
setKeywords in interface MapContextkeywords - New value of property keywords.
java.lang.NullPointerException - DOCUMENT ME!public java.lang.String getTitle()
getTitle in interface MapContextpublic void setTitle(java.lang.String title)
setTitle in interface MapContexttitle - New value of property title.
java.lang.NullPointerException - DOCUMENT ME!public void addMapLayerListListener(MapLayerListListener listener)
addMapLayerListListener in interface MapContextlistener - The listener to register.public void removeMapLayerListListener(MapLayerListListener listener)
removeMapLayerListListener in interface MapContextlistener - The listener to remove.public void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
addPropertyChangeListener in interface MapContextlistener - The listener to register.public void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
removePropertyChangeListener in interface MapContextlistener - The listener to remove.public void addMapBoundsListener(MapBoundsListener listener)
addMapBoundsListener in interface MapContextlistener - The listener to register.public void removeMapBoundsListener(MapBoundsListener listener)
removeMapBoundsListener in interface MapContextlistener - The listener to remove.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||