public enum Convention extends Enum<Convention>
AXIS[…]elements in the WKT.
WKT1_COMMON_UNITSenumeration allows parsing and formatting using the older interpretation. The
WKT1_IGNORE_AXESenumeration mimics the most minimalist WKT 1 parsers, but should be avoided when not imposed by compatibility reasons.
|Enum Constant and Description|
A special convention for formatting objects as stored internally by Apache SIS.
The OGC 01-009 format, also known as “WKT 1”.
The Simple Feature format, also known as “WKT 1”.
The Simple Feature format without parsing of axis elements.
The ISO 19162 format, also known as “WKT 2”.
The ISO 19162 format with omission of some optional elements.
|Modifier and Type||Method and Description|
Returns the major version of the Well Known Text represented by this convention.
Returns the enum constant of this type with the specified name.
Returns an array containing the constants of this enum type, in the order they are declared.
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
public static final Convention WKT2
public static final Convention WKT2_SIMPLIFIED
WKT2convention except for the following aspects:
"GeodCRS") except for the
"Unit"keyword, because they match the class or interface names.
PrimeMeridianelement omitted if the meridian is Greenwich.
Axiselement omits the
Unitelements are less verbose:
VerticalExtentelements omit the
LengthUnitsub-element if that unit is
Parameterelements omit the
LengthUnitsub-element if that unit is the same than the unit of the
PrimeMeridianelements omit the
AngleUnitsub-element if that unit is the same than the unit of the
TimeUnitare formatted as plain
Idis formatted only for the root element (omit parameters and operation methods
This is the default convention used by
public static final Convention WKT1
GeocentricCRS, WKT 1 uses a legacy set of Cartesian axes which were defined in OGC 01-009. Those axes use the Other, Easting and Northing axis directions instead than the geocentric ones. For more uniform handling of CRS objects in client code, SIS parser replaces some WKT 1 conventions by the ISO ones when possible.
public static final Convention WKT1_COMMON_UNITS
This convention is identical to
WKT1 except for the following aspects:
PARAMETERelements are always degrees, no matter the units of the enclosing
public static final Convention WKT1_IGNORE_AXES
WKT1_COMMON_UNITSexcept that all
AXIS[…]elements are ignored. Since the WKT 1 specification said that the default axis order shall be (x,y) or (longitude, latitude), ignoring
AXIS[…]elements is equivalent to forcing the coordinate systems to that default order.
AXIS[…] elements still need to be well formed even when parsing a text with this convention.
Malformed axis elements will continue to cause a
ParseException despite their content being ignored.
This convention may be useful for compatibility with some other software products that do not handle axis order correctly. But except when imposed by such compatibility reasons, this convention should be avoided as much as possible.
@Debug public static final Convention INTERNAL
WKT2_SIMPLIFIEDconvention, with the following differences:
Parameterelements omit the unit of measurement if that unit is equal to the default unit (as declared in the parameter descriptor).
CompoundCRSelements show nested compound CRS if any (the structure is not flattened).
Idelements are formatted for child elements in addition to the root one.
Idelement omits the
URIsub-element if the later is derived by Apache SIS from the
Remarkselement is formatted for all identified objects, not only CRS or coordinate operations.
public static Convention values()
for (Convention c : Convention.values()) System.out.println(c);
public static Convention valueOf(String name)
public int majorVersion()
public boolean isSimplified()
trueif this convention is one of the simplified variants of WKT. The simplifications are documented in the
This methods consider version 1 of WKT as a “simplified” convention, since this version was indeed simpler than version 2.
trueit this convention uses a simplified variant of WKT.
Copyright © 2010–2017 The Apache Software Foundation. All rights reserved.