Class TLcdWKTReferenceParser

java.lang.Object
com.luciad.reference.format.TLcdWKTReferenceParser
All Implemented Interfaces:
ILcdModelReferenceParser, ILcdXYWorldReferenceParser

public class TLcdWKTReferenceParser extends Object implements ILcdModelReferenceParser, ILcdXYWorldReferenceParser
This class is used to parse Coordinate Reference Systems in the Well-Known Text format of the OpenGIS Specification to a ILcdModelReference of LuciadLightspeed. The WKT format is specified in OGC document 01-009 (OpenGIS Coordinate Transformation Service Implementation Specification).

If the reference uses a "Lambert Conic Conformal (2SP Belgium)" projection, it is considered the same as EPSG:31300 and a corresponding TLcdLambert1972BelgiumGridReference reference is created.
If the reference starts with "Amersfoort / RD New" then a TLcdRD1918DutchGridReference reference will be created.

Note on references having a vertical datum (geoid).

Vertical references that are unsupported are approximated by using the EGM2008 geoid as base geoid. This is only done when the unit of measure of the vertical reference is expressed in meters.

It is possible to disable this behavior by using the system property "com.luciad.reference.format.allowApproximateVerticalReference" with a value false.

  • Constructor Details

    • TLcdWKTReferenceParser

      public TLcdWKTReferenceParser()
  • Method Details

    • setClassTraceOn

      public static void setClassTraceOn(boolean aClassTraceOn)
      Deprecated.
      This method has been deprecated. It is recommended to use the standard Java logging framework directly.
      Enables tracing for all instances of this class. If the argument is true then all log messages are recorded, otherwise only the informative, warning and error messages are recorded.
      Parameters:
      aClassTraceOn - if true then all log messages are recorded, otherwise only the informative, warning and error messages are recorded.
    • parseModelReference

      public ILcdModelReference parseModelReference(String aModelReferenceAsString) throws ParseException
      Decodes the model reference. This model reference can be geographic or projected.
      Specified by:
      parseModelReference in interface ILcdModelReferenceParser
      Parameters:
      aModelReferenceAsString - the String representation of the ILcdModelReference.
      Returns:
      the ILcdModelReference that is formatted as a String.
      Throws:
      ParseException - if the ILcdModelReference cannot be created from the String.
    • parseXYWorldReference

      public ILcdXYWorldReference parseXYWorldReference(String aXYWorldReferenceAsString) throws ParseException
      Decodes the world reference. This world reference can be geographic or projected. Geographic references are wrapped in a TLcdGeodetic projection.
      Specified by:
      parseXYWorldReference in interface ILcdXYWorldReferenceParser
      Parameters:
      aXYWorldReferenceAsString - the String representation of the ILcdXYWorldReference.
      Returns:
      the ILcdXYWorldReference that is formatted as a String.
      Throws:
      ParseException - if the ILcdXYWorldReference cannot be created from the String.
    • parseGeodeticDatum

      public ILcdGeodeticDatum parseGeodeticDatum(String aGeodeticDatumAsWKT) throws ParseException
      Decodes the geodetic datum from its WKT representation.
      Parameters:
      aGeodeticDatumAsWKT - the WKT representation of the geodetic datum.
      Returns:
      the geodetic datum.
      Throws:
      ParseException - if the geodetic datum cannot be created from the string.
    • parseEllipsoid

      public ILcdEllipsoid parseEllipsoid(String aEllipsoidAsWKT) throws ParseException
      Decodes the ellipsoid from its WKT representation.
      Parameters:
      aEllipsoidAsWKT - - the String representation of the ellipsoid.
      Returns:
      the ellipsoid.
      Throws:
      ParseException - if the ellipsoid cannot be parsed from the string.