001/* 002 * GeoAPI - Java interfaces for OGC/ISO standards 003 * Copyright © 2003-2023 Open Geospatial Consortium, Inc. 004 * http://www.geoapi.org 005 * 006 * Licensed under the Apache License, Version 2.0 (the "License"); 007 * you may not use this file except in compliance with the License. 008 * You may obtain a copy of the License at 009 * 010 * http://www.apache.org/licenses/LICENSE-2.0 011 * 012 * Unless required by applicable law or agreed to in writing, software 013 * distributed under the License is distributed on an "AS IS" BASIS, 014 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 015 * See the License for the specific language governing permissions and 016 * limitations under the License. 017 */ 018package org.opengis.referencing.cs; 019 020import org.opengis.referencing.IdentifiedObject; 021import org.opengis.annotation.UML; 022import org.opengis.annotation.Classifier; 023import org.opengis.annotation.Stereotype; 024 025import static org.opengis.annotation.Obligation.*; 026import static org.opengis.annotation.Specification.*; 027 028 029/** 030 * Sequence of non-repeating coordinate system axes that spans a given coordinate space. 031 * A coordinate system (CS) is derived from a set of (mathematical) rules 032 * for specifying how coordinates in a given space are to be assigned to points. 033 * The coordinate values in a coordinate tuple shall be recorded 034 * in the order in which the coordinate system axes associations are recorded. 035 * 036 * @author OGC Topic 2 (for abstract model and documentation) 037 * @author Martin Desruisseaux (IRD, Geomatys) 038 * @version 3.1 039 * @since 1.0 040 * 041 * @see org.opengis.referencing.cs.CoordinateSystemAxis 042 * @see org.opengis.referencing.datum.Datum 043 * @see org.opengis.referencing.crs.CoordinateReferenceSystem 044 */ 045@Classifier(Stereotype.ABSTRACT) 046@UML(identifier="CoordinateSystem", specification=ISO_19111) 047public interface CoordinateSystem extends IdentifiedObject { 048 /** 049 * Returns the dimension of the coordinate system. 050 * 051 * @return the dimension of the coordinate system. 052 */ 053 int getDimension(); 054 055 /** 056 * Returns the axis for this coordinate system at the specified dimension. 057 * Each coordinate system must have at least one axis. 058 * 059 * @param dimension the zero based index of axis. 060 * @return the axis at the specified dimension. 061 * @throws IndexOutOfBoundsException if {@code dimension} is out of bounds. 062 */ 063 @UML(identifier="axis", obligation=MANDATORY, specification=ISO_19111) 064 CoordinateSystemAxis getAxis(int dimension) throws IndexOutOfBoundsException; 065}