KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jscience > geography > coordinates > crs > VerticalCRS


1 /*
2  * JScience - Java(TM) Tools and Libraries for the Advancement of Sciences.
3  * Copyright (C) 2006 - JScience (http://jscience.org/)
4  * All rights reserved.
5  *
6  * Permission to use, copy, modify, and distribute this software is
7  * freely granted, provided that this notice is preserved.
8  */

9 package org.jscience.geography.coordinates.crs;
10
11 import java.util.Collection JavaDoc;
12 import java.util.Set JavaDoc;
13
14 import javax.measure.units.SI;
15
16 import org.jscience.geography.coordinates.Coordinates;
17 import org.opengis.metadata.Identifier;
18 import org.opengis.referencing.cs.AxisDirection;
19 import org.opengis.referencing.cs.CoordinateSystem;
20 import org.opengis.referencing.cs.CoordinateSystemAxis;
21 import org.opengis.util.InternationalString;
22
23 /**
24  * This class represents a 1 dimensional vertical reference system.
25  *
26  * @author <a HREF="mailto:jean-marie@dautelle.com">Jean-Marie Dautelle</a>
27  * @version 3.0, February 13, 2006
28  */

29 public abstract class VerticalCRS<C extends Coordinates> extends CoordinateReferenceSystem<C> {
30     
31     /**
32      * Holds the gravity-related height coordinate system.
33      */

34     public static final CoordinateSystem HEIGHT_CS = new CoordinateSystem() {
35
36         Axis heightAxis = new Axis("Gravity-related height", "Height", SI.METER,
37                 AxisDirection.UP);
38
39         public int getDimension() {
40             return 1;
41         }
42
43         public CoordinateSystemAxis getAxis(int dimension)
44                 throws IndexOutOfBoundsException JavaDoc {
45             if (dimension == 0) {
46                 return heightAxis;
47             } else {
48                 throw new IndexOutOfBoundsException JavaDoc();
49             }
50         }
51
52         public Identifier getName() {
53             throw new UnsupportedOperationException JavaDoc();
54         }
55
56         public Collection JavaDoc getAlias() {
57             return EMPTY_SET;
58         }
59
60         public Set JavaDoc getIdentifiers() {
61             return EMPTY_SET;
62         }
63
64         public InternationalString getRemarks() {
65             throw new UnsupportedOperationException JavaDoc();
66         }
67
68         public String JavaDoc toWKT() throws UnsupportedOperationException JavaDoc {
69             throw new UnsupportedOperationException JavaDoc();
70         }
71     };
72
73 }
Popular Tags