public class MapBoundsEvent extends EventObject
Modifier and Type | Class and Description |
---|---|
static class |
MapBoundsEvent.Type
Type of map bounds event
|
Modifier and Type | Field and Description |
---|---|
static int |
AREA_OF_INTEREST_MASK
Area of interest changed, mask used by
MapBoundsEvent.Type.BOUNDS |
static int |
COORDINATE_SYSTEM_MASK
Coordinate system changed, mask used by
MapBoundsEvent.Type.CRS |
source
Constructor and Description |
---|
MapBoundsEvent(MapContext source,
int type,
ReferencedEnvelope oldAreaOfInterest,
ReferencedEnvelope newAreaOfInterest)
Creates a new instance of BoundsEvent
|
MapBoundsEvent(MapViewport source,
EnumSet<MapBoundsEvent.Type> type,
ReferencedEnvelope oldBounds,
ReferencedEnvelope newBounds)
Creates a new instance of BoundsEvent.
|
MapBoundsEvent(MapViewport source,
MapBoundsEvent.Type type,
ReferencedEnvelope oldBounds,
ReferencedEnvelope newBounds)
Creates a new instance of BoundsEvent.
|
Modifier and Type | Method and Description |
---|---|
EnumSet<MapBoundsEvent.Type> |
getEventType()
Set of event types raised for this event.
|
ReferencedEnvelope |
getNewAreaOfInterest()
Get the new area of interest
|
CoordinateReferenceSystem |
getNewCoordinateReferenceSystem()
Get the new coordinate reference system.
|
ReferencedEnvelope |
getOldAreaOfInterest()
Get the old area of interest
|
CoordinateReferenceSystem |
getOldCoordinateReferenceSystem()
Get the previous coordinate reference system.
|
int |
getType()
Getter for property type.
|
getSource, toString
public static final int AREA_OF_INTEREST_MASK
MapBoundsEvent.Type.BOUNDS
public static final int COORDINATE_SYSTEM_MASK
MapBoundsEvent.Type.CRS
public MapBoundsEvent(MapContext source, int type, ReferencedEnvelope oldAreaOfInterest, ReferencedEnvelope newAreaOfInterest)
source
- the map context reporting the changetype
- the type of change indicated by one or both of the bit masks AREA_OF_INTEREST_MASK and COORDINATE_SYSTEM_MASKoldAreaOfInterest
- the context's previous area of interestnewAreaOfInterest
- the context's new area of interestIllegalArgumentException
- if type is invalidpublic MapBoundsEvent(MapViewport source, MapBoundsEvent.Type type, ReferencedEnvelope oldBounds, ReferencedEnvelope newBounds)
Example:
new MapBoundsEvent(map, EnumSet.of(Type.BOUNDS), null, bounds)
source
- map viewport reporting the changetype
- Type of event indicating MapBoundsEvent.Type.BOUNDS
or MapBoundsEvent.Type.CRS
oldAreaOfInterest
- the context's previous area of interestnewAreaOfInterest
- the context's new area of interestIllegalArgumentException
- if type is invalidpublic MapBoundsEvent(MapViewport source, EnumSet<MapBoundsEvent.Type> type, ReferencedEnvelope oldBounds, ReferencedEnvelope newBounds)
Example:
new MapBoundsEvent(map, EnumSet.of(Type.BOUNDS), null, bounds)
source
- map viewport reporting the changetype
- EnumSet flagging one or both of the following AREA_OF_INTEREST_MASK
and COORDINATE_SYSTEM_MASKoldAreaOfInterest
- the context's previous area of interestnewAreaOfInterest
- the context's new area of interestIllegalArgumentException
- if type is invalidpublic int getType()
public EnumSet<MapBoundsEvent.Type> getEventType()
public CoordinateReferenceSystem getOldCoordinateReferenceSystem()
public CoordinateReferenceSystem getNewCoordinateReferenceSystem()
public ReferencedEnvelope getOldAreaOfInterest()
public ReferencedEnvelope getNewAreaOfInterest()
Copyright © 1996–2019 Geotools. All rights reserved.