Class EllipsoidalHeightSeparator

java.lang.Object
org.apache.sis.referencing.EllipsoidalHeightSeparator
All Implemented Interfaces:
AxisFilter

final class EllipsoidalHeightSeparator extends Object implements AxisFilter
Helper class for separating the ellipsoidal height from the horizontal part of a CRS. This is the converse of EllipsoidalHeightCombiner.
Since:
1.0
Version:
1.1
See Also:
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private final org.opengis.referencing.datum.GeodeticDatum
    The value of SingleCRS.getDatum().
    private final boolean
    Whether to extract the vertical component (true) or the horizontal component (false).
  • Constructor Summary

    Constructors
    Constructor
    Description
    EllipsoidalHeightSeparator(org.opengis.referencing.datum.GeodeticDatum datum, boolean vertical)
    Creates a new separator for a CRS having the given datum.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    accept(org.opengis.referencing.cs.CoordinateSystemAxis axis)
    Returns true if the given axis shall be included in the new coordinate system.
    private static org.opengis.referencing.crs.CRSFactory
    The factory to use for creating new coordinate reference system.
    (package private) org.opengis.referencing.crs.SingleCRS
    separate(org.opengis.referencing.crs.SingleCRS crs)
    Extracts the horizontal or vertical component of the coordinate reference system.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.apache.sis.referencing.cs.AxisFilter

    getDirectionReplacement, getUnitReplacement
  • Field Details

    • datum

      private final org.opengis.referencing.datum.GeodeticDatum datum
      The value of SingleCRS.getDatum().
    • vertical

      private final boolean vertical
      Whether to extract the vertical component (true) or the horizontal component (false).
  • Constructor Details

    • EllipsoidalHeightSeparator

      EllipsoidalHeightSeparator(org.opengis.referencing.datum.GeodeticDatum datum, boolean vertical)
      Creates a new separator for a CRS having the given datum.
      Parameters:
      datum - the datum of the CRS to separate.
      vertical - whether to extract the vertical component (true) or the horizontal component (false).
  • Method Details

    • accept

      public boolean accept(org.opengis.referencing.cs.CoordinateSystemAxis axis)
      Returns true if the given axis shall be included in the new coordinate system.
      Specified by:
      accept in interface AxisFilter
      Parameters:
      axis - the axis to test.
      Returns:
      true if the given axis shall be included in the new coordinate system.
    • factory

      private static org.opengis.referencing.crs.CRSFactory factory()
      The factory to use for creating new coordinate reference system.
    • separate

      org.opengis.referencing.crs.SingleCRS separate(org.opengis.referencing.crs.SingleCRS crs) throws org.opengis.util.FactoryException
      Extracts the horizontal or vertical component of the coordinate reference system.
      Parameters:
      crs - the coordinate reference system from which to extract the horizontal or vertical component.
      Returns:
      the requested component.
      Throws:
      IllegalArgumentException - if the specified coordinate system cannot be filtered. It may be because the coordinate system would contain an illegal number of axes, or because an axis would have an unexpected direction or unexpected unit of measurement.
      ClassCastException - if a coordinate system is not of the expected type.
      org.opengis.util.FactoryException