public class ClosedShapeGeoFenceMonitor extends GeoFenceMonitor
GeoFenceMonitor.Factory
_item, _uidsLastState, _view
Constructor and Description |
---|
ClosedShapeGeoFenceMonitor(MapView view,
SpatialCalculator spatialCalc,
GeoFence fence,
DrawingShape item)
ctor
|
Modifier and Type | Method and Description |
---|---|
protected java.util.List<GeoFenceAlerting.Alert> |
check(GeoFence.Trigger trigger,
java.util.List<PointMapItem> items,
boolean bCheckPrevious)
Check if any tracked items have breached the Geo Fence
All items passed in so subclasses can optimize shape comparison math
|
void |
dispose() |
GeoPointMetaData |
getCenter()
Get center of monitored area
|
double |
getfurthestPointRange() |
boolean |
isValid() |
boolean |
removeItem(PointMapItem item)
Remove tracking for the dismissed item
|
addItem, check, check, checkDismissed, checkSelectedItem, checkTrigger, checkTrigger, clearSelectItems, clearUidsLastState, equals, getFence, getItem, getItems, getLastState, getMapItemUid, getRescanItems, getSelectedItemUids, hashCode, hasTrackedItems, inElevationRange, isMonitoring, persist, setFence, setSelectItems, setSelectUids, setUidsLastState, size, toString
public ClosedShapeGeoFenceMonitor(MapView view, SpatialCalculator spatialCalc, GeoFence fence, DrawingShape item)
view
- the map viewspatialCalc
- the spatial calculatorfence
- the geofence to be useditem
- shape with at least 3 pointspublic boolean isValid()
isValid
in class GeoFenceMonitor
public void dispose()
dispose
in class GeoFenceMonitor
public boolean removeItem(PointMapItem item)
GeoFenceMonitor
removeItem
in class GeoFenceMonitor
protected java.util.List<GeoFenceAlerting.Alert> check(GeoFence.Trigger trigger, java.util.List<PointMapItem> items, boolean bCheckPrevious)
GeoFenceMonitor
check
in class GeoFenceMonitor
trigger
- the trigger to be useditems
- the list of itemsbCheckPrevious
- if true, only alert if current state differs from previous statepublic GeoPointMetaData getCenter()
GeoFenceMonitor
getCenter
in class GeoFenceMonitor
public double getfurthestPointRange()
getfurthestPointRange
in class GeoFenceMonitor