com.isti.util.gis
Class IstiRegion.Circle

java.lang.Object
  extended by com.isti.util.gis.IstiRegion
      extended by com.isti.util.gis.IstiRegion.Circle
Enclosing class:
IstiRegion

public static class IstiRegion.Circle
extends IstiRegion

Circle region.


Nested Class Summary
 
Nested classes/interfaces inherited from class com.isti.util.gis.IstiRegion
IstiRegion.Circle, IstiRegion.LatLonPoint, IstiRegion.LatLonPolygon, IstiRegion.Polygon
 
Field Summary
protected  IstiRegion.LatLonPoint midPt
           
protected  double radius
           
 
Fields inherited from class com.isti.util.gis.IstiRegion
ageValidator, COORD_BEGIN_CHAR, COORD_END_CHAR, COORD_SEP_CHAR, DEF_SPECIAL_CHARS_STR, defaultConversionFactor, depthValidator, GLOBAL_ALARM_OPTION_GROUP, magValidator, NAME_BEGIN_CHAR, NAME_END_CHAR, OPID_AUDIBLE, OPID_MAG, OPID_MAXAGE, OPID_MAXDEPTH, OPID_MINDEPTH, OPID_NAME, OPID_VERIFIED, OPID_VISUAL, OPTION_BEGIN_CHAR, OPTION_END_CHAR, REGION_SEP_CHAR, regionTextValueStr
 
Constructor Summary
  IstiRegion.Circle(double lat, double lon, double radius)
          Creates a region defined by the circle
protected IstiRegion.Circle(IstiRegion.Circle circle)
          Constructs a region.
protected IstiRegion.Circle(java.lang.String str)
          Constructs a region.
 
Method Summary
 java.lang.Object clone()
          Creates a copy of a region.
 boolean contains(double lat, double lon)
          Determines if the specified point is inside of the region.
 double getLat()
          Gets the latitude point.
 double getLon()
          Gets the longitude point.
 double getRadius()
          Gets the radius in meters.
 
Methods inherited from class com.isti.util.gis.IstiRegion
circleToString, coordsToString, coordToString, copyOptions, createOptionsComponentPanel, extractRegionName, floatNumberToString, getDefaultOptions, getName, getOption, getOptionNumberValue, getOptionStringValue, getOptionValue, getRegionTextValueStr, insertQuoteChars, parse, parse, parseOptions, parseRegions, radiusToString, removeQuoteChars, replaceRegionName, setOptionValue, stringToCoord, stringToCoords, stringToRadius, toString
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

midPt

protected final IstiRegion.LatLonPoint midPt

radius

protected final double radius
Constructor Detail

IstiRegion.Circle

public IstiRegion.Circle(double lat,
                         double lon,
                         double radius)
Creates a region defined by the circle

Parameters:
lat - the latitude of the point.
lon - the longitude of the point.
radius - the radius of the circle in meters.

IstiRegion.Circle

protected IstiRegion.Circle(IstiRegion.Circle circle)
Constructs a region.

Parameters:
circle - the circle to copy.

IstiRegion.Circle

protected IstiRegion.Circle(java.lang.String str)
                     throws java.lang.InstantiationException
Constructs a region.

Parameters:
str - string representation of the region.
Throws:
java.lang.InstantiationException - if the class cannot be instantiated.
Method Detail

clone

public java.lang.Object clone()
Creates a copy of a region.

Overrides:
clone in class IstiRegion
Returns:
a copy of the region.

contains

public boolean contains(double lat,
                        double lon)
Determines if the specified point is inside of the region.

Overrides:
contains in class IstiRegion
Parameters:
lat - the latitude of the point.
lon - the longitude of the point.
Returns:
true if the point is inside the region, false otherwise.

getLat

public double getLat()
Gets the latitude point.

Returns:
the latitude point.

getLon

public double getLon()
Gets the longitude point.

Returns:
the longitude point.

getRadius

public double getRadius()
Gets the radius in meters.

Returns:
the radius.