|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectucar.nc2.dataset.CoordinateSystem
public class CoordinateSystem
A CoordinateSystem specifies the coordinates of a Variable's values. Mathmatically it is a vector function F from index space to Sn:
F(i,j,k,...) -> (S1, S2, ...Sn) where i,j,k are integers, and S is the set of reals (R) or Strings.The components of F are just its coordinate axes:
F = (A1, A2, ...An)
A1(i,j,k,...) -> S1
A2(i,j,k,...) -> S1
An(i,j,k,...) -> Sn
Concretely, a CoordinateSystem is a set of coordinate axes, and an optional set
of coordinate transforms.
The domain rank of F is the number of dimensions it is a function of. The range rank is the number
of coordinate axes.
An important class of CoordinateSystems are georeferencing Coordinate Systems, that locate a Variable's values in space and time. A CoordinateSystem that has a Lat and Lon axis, or a GeoX and GeoY axis and a Projection CoordinateTransform will have isGeoReferencing() true. A CoordinateSystem that has a Height, Pressure, or GeoZ axis will have hasVerticalAxis() true.
Further CoordinateSystems specialization is done by "data type specific" clasess such as ucar.nc2.dt.grid.GridCoordSys.
| Field Summary | |
|---|---|
protected CoordinateAxis |
aziAxis
|
protected java.util.ArrayList |
coordAxes
|
protected java.util.ArrayList |
coordTrans
|
protected java.lang.String |
dataType
|
protected java.util.ArrayList |
domain
|
protected NetcdfDataset |
ds
|
protected CoordinateAxis |
elevAxis
|
protected CoordinateAxis |
hAxis
|
protected boolean |
isImplicit
|
protected CoordinateAxis |
latAxis
|
protected CoordinateAxis |
lonAxis
|
protected java.lang.String |
name
|
protected CoordinateAxis |
pAxis
|
protected CoordinateAxis |
radialAxis
|
protected CoordinateAxis |
tAxis
|
protected CoordinateAxis |
xAxis
|
protected CoordinateAxis |
yAxis
|
protected CoordinateAxis |
zAxis
|
| Constructor Summary | |
|---|---|
protected |
CoordinateSystem()
|
|
CoordinateSystem(NetcdfDataset ds,
java.util.Collection axes,
java.util.Collection coordTrans)
Constructor. |
| Method Summary | |
|---|---|
void |
addCoordinateTransform(CoordinateTransform ct)
add a CoordinateTransform |
void |
addCoordinateTransforms(java.util.Collection ct)
add a Collection of CoordinateTransform |
boolean |
containsAxes(java.util.List wantAxes)
Do we have all the axes in the list? |
boolean |
containsAxis(java.lang.String axisName)
Do we have the named axis? |
boolean |
containsAxisType(AxisType wantAxisType)
Do we have an axes of the given type? |
boolean |
containsAxisTypes(java.util.List wantAxes)
Do we have all the axes types in the list? |
boolean |
containsDomain(java.util.List wantDimensions)
Do we have all the dimensions in the list? |
boolean |
equals(java.lang.Object oo)
Instances which have same name are equal. |
CoordinateAxis |
findAxis(AxisType type)
Find the CoordinateAxis that has the given AxisType. |
CoordinateAxis |
getAzimuthAxis()
get the CoordinateAxis with AxisType.RadialAzimuth, or null if none. |
java.util.List |
getCoordinateAxes()
get the List of CoordinateAxis objects |
java.util.List |
getCoordinateTransforms()
get the List of CoordinateTransform objects |
java.util.List |
getDomain()
List of Dimensions that constitute the domain. |
CoordinateAxis |
getElevationAxis()
get the CoordinateAxis with AxisType.RadialElevation, or null if none. |
CoordinateAxis |
getHeightAxis()
get the CoordinateAxis with AxisType.Height, or null if none. |
CoordinateAxis |
getLatAxis()
get the CoordinateAxis with AxisType.Lat, or null if none. |
CoordinateAxis |
getLonAxis()
get the CoordinateAxis with AxisType.Lon, or null if none. |
java.lang.String |
getName()
get the name of the Coordinate System |
CoordinateAxis |
getPressureAxis()
get the CoordinateAxis with AxisType.Pressure, or null if none. |
ProjectionImpl |
getProjection()
Get the Projection for this coordinate system. |
ProjectionCT |
getProjectionCT()
Find the first ProjectionCT from the list of CoordinateTransforms. |
CoordinateAxis |
getRadialAxis()
get the CoordinateAxis with AxisType.RadialDistance, or null if none. |
int |
getRankDomain()
Get the domain rank of the coordinate system = number of dimensions it is a function of. |
int |
getRankRange()
Get the range rank of the coordinate system = number of coordinate axes. |
CoordinateAxis |
getTaxis()
get the CoordinateAxis with AxisType.Time, or null if none. |
CoordinateAxis |
getXaxis()
get the CoordinateAxis with AxisType.GeoX, or null if none. |
CoordinateAxis |
getYaxis()
get the CoordinateAxis with AxisType.GeoY, or null if none. |
CoordinateAxis |
getZaxis()
get the CoordinateAxis with AxisType.GeoZ, or null if none. |
int |
hashCode()
Override Object.hashCode() to implement equals. |
boolean |
hasTimeAxis()
true if has Time axis |
boolean |
hasVerticalAxis()
true if has Height, Pressure, or GeoZ axis |
boolean |
isComplete(VariableIF v)
true if all dimensions in V (including parents) are in the domain of this coordinate system. |
boolean |
isGeoReferencing()
true if isGeoXY or isLatLon |
boolean |
isGeoXY()
true if it has X and Y CoordinateAxis, and a CoordTransform Projection |
boolean |
isImplicit()
Implicit Coordinate System are constructed based on whatr Coordinate Variables are being used. |
boolean |
isLatLon()
true if it has Lat and Lon CoordinateAxis |
boolean |
isProductSet()
true if all axes are CoordinateAxis1D |
boolean |
isRadial()
true if it has radial distance and azimuth CoordinateAxis |
boolean |
isRegular()
true if all axes are CoordinateAxis1D and are regular |
static java.lang.String |
makeName(java.util.List axes)
Create standard name from list of axes. |
protected void |
setImplicit(boolean isImplicit)
Set whether this Coordinate System is implicit |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected NetcdfDataset ds
protected java.util.ArrayList coordAxes
protected java.util.ArrayList coordTrans
protected java.util.ArrayList domain
protected java.lang.String name
protected CoordinateAxis xAxis
protected CoordinateAxis yAxis
protected CoordinateAxis zAxis
protected CoordinateAxis tAxis
protected CoordinateAxis latAxis
protected CoordinateAxis lonAxis
protected CoordinateAxis hAxis
protected CoordinateAxis pAxis
protected CoordinateAxis aziAxis
protected CoordinateAxis elevAxis
protected CoordinateAxis radialAxis
protected boolean isImplicit
protected java.lang.String dataType
| Constructor Detail |
|---|
protected CoordinateSystem()
public CoordinateSystem(NetcdfDataset ds,
java.util.Collection axes,
java.util.Collection coordTrans)
axes - Collection of type CoordinateAxis, must be at least one.coordTrans - Collection of type CoordinateTransform, may be empty or null.| Method Detail |
|---|
public static java.lang.String makeName(java.util.List axes)
public void addCoordinateTransform(CoordinateTransform ct)
public void addCoordinateTransforms(java.util.Collection ct)
public java.util.List getCoordinateAxes()
public java.util.List getCoordinateTransforms()
public java.lang.String getName()
public java.util.List getDomain()
public int getRankDomain()
public int getRankRange()
public CoordinateAxis findAxis(AxisType type)
type -
public CoordinateAxis getXaxis()
public CoordinateAxis getYaxis()
public CoordinateAxis getZaxis()
public CoordinateAxis getTaxis()
public CoordinateAxis getLatAxis()
public CoordinateAxis getLonAxis()
public CoordinateAxis getHeightAxis()
public CoordinateAxis getPressureAxis()
public CoordinateAxis getAzimuthAxis()
public CoordinateAxis getRadialAxis()
public CoordinateAxis getElevationAxis()
public ProjectionCT getProjectionCT()
public ProjectionImpl getProjection()
public boolean isGeoXY()
public boolean isLatLon()
public boolean isRadial()
public boolean isGeoReferencing()
public boolean isProductSet()
public boolean isRegular()
public boolean isComplete(VariableIF v)
public boolean isImplicit()
protected void setImplicit(boolean isImplicit)
public boolean hasVerticalAxis()
public boolean hasTimeAxis()
public boolean containsAxes(java.util.List wantAxes)
wantAxes - List of CoordinateAxis
public boolean containsAxis(java.lang.String axisName)
axisName - name of axis
public boolean containsDomain(java.util.List wantDimensions)
wantDimensions - List of Dimensions
public boolean containsAxisTypes(java.util.List wantAxes)
wantAxes - List of AxisType
public boolean containsAxisType(AxisType wantAxisType)
wantAxisType - want this AxisType
public boolean equals(java.lang.Object oo)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||