Package uk.ac.rdg.resc.edal.position
Class VerticalCrsImpl
- java.lang.Object
-
- uk.ac.rdg.resc.edal.position.VerticalCrsImpl
-
- All Implemented Interfaces:
Serializable,VerticalCrs
public class VerticalCrsImpl extends Object implements VerticalCrs
Implementation of aVerticalCrs- Author:
- Guy
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description VerticalCrsImpl(String units, boolean pressure, boolean dimensionless, boolean positiveUpwards)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)StringgetUnits()Returns the units for the values in thisVerticalCrsinthashCode()booleanisDimensionless()Return true if this is a dimensionless (e.g.booleanisPositiveUpwards()Indicates whether coordinate values increase upward or downward.booleanisPressure()Return true if this axis has units of pressure.StringtoString()
-
-
-
Constructor Detail
-
VerticalCrsImpl
public VerticalCrsImpl(String units, boolean pressure, boolean dimensionless, boolean positiveUpwards)
-
-
Method Detail
-
getUnits
public String getUnits()
Description copied from interface:VerticalCrsReturns the units for the values in thisVerticalCrsTODO This may need replacing with a stronger type
- Specified by:
getUnitsin interfaceVerticalCrs
-
isPressure
public boolean isPressure()
Description copied from interface:VerticalCrsReturn true if this axis has units of pressure. If this is true then the positive direction must be DOWN.- Specified by:
isPressurein interfaceVerticalCrs
-
isDimensionless
public boolean isDimensionless()
Description copied from interface:VerticalCrsReturn true if this is a dimensionless (e.g. sigma or terrain-following) coordinate system. If this is true then the units are irrelevant, and isPressure() will return false.
Future APIs will need to allow conversions between dimensionless and dimensional coordinates, which will require more information. (The conversion can be performed using existing routines, e.g. in Java-NetCDF.) However, the current purpose of EDAL is not to perform the conversion but to provide client code with enough information to decide what to do.
- Specified by:
isDimensionlessin interfaceVerticalCrs- See Also:
- CF conventions
-
isPositiveUpwards
public boolean isPositiveUpwards()
Description copied from interface:VerticalCrsIndicates whether coordinate values increase upward or downward.- Specified by:
isPositiveUpwardsin interfaceVerticalCrs
-
hashCode
public int hashCode()
- Specified by:
hashCodein interfaceVerticalCrs- Overrides:
hashCodein classObject
-
equals
public boolean equals(Object obj)
- Specified by:
equalsin interfaceVerticalCrs- Overrides:
equalsin classObject
-
-