public class GeoLong extends ValueConstruct
W3CPointAbstractExtension.AttributesHandler| Modifier and Type | Field and Description |
|---|---|
static int |
COORDINATE_PRECISION
This denotes the number of significant digits after the decimal point
for a coordinate when represented by a string.
|
static double |
MAX_LONG
The maximmum acceptable value of a longitude coordinate in degrees.
|
static double |
MIN_LONG
The minimum acceptable value of a longitude coordinate in degrees.
|
attrNamelocalName, namespace| Constructor and Description |
|---|
GeoLong()
Creates an instance of the GeoLong extension without a
longitude value set.
|
GeoLong(java.lang.Double lon)
Creates an immutable instance of GeoLong extension with the coordinate
set to the value passed in.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.Double |
getLongitude()
Returns the actual double coordinate for longitude.
|
void |
setLongitude(java.lang.Double longitude)
Sets the longitude represented by this element.
|
void |
setValue(java.lang.String value)
Overrides base implementation by validating that the string represents
a longitude coordinate between -180 and 180 degrees.
|
consumeAttributes, equals, generate, getHandler, getValue, hashCode, hasValue, isRequired, putAttributes, setRequireddisableStrictValidation, enableStrictValidation, eq, generate, generateAttributes, getExtensionLocalName, getExtensionNamespace, isImmutable, isStrictValidation, sameClassAs, setImmutable, throwExceptionForMissingAttribute, throwExceptionIfImmutable, validatepublic static final double MAX_LONG
public static final double MIN_LONG
public static final int COORDINATE_PRECISION
public GeoLong()
public GeoLong(java.lang.Double lon)
throws java.lang.IllegalArgumentException
lon - The longitude coordinate reprensented by this element.java.lang.IllegalArgumentException - if the longitude is not between
-180 and 180 degrees.public java.lang.Double getLongitude()
public void setLongitude(java.lang.Double longitude)
longitude - the longitude of this element.public void setValue(java.lang.String value)
setValue in class ValueConstructvalue - new value for the value construct or null to reset.