001 /*
002 * GeoAPI - Java interfaces for OGC/ISO standards
003 * http://www.geoapi.org
004 *
005 * This file is hereby placed into the Public Domain.
006 * This means anyone is free to do whatever they wish with this file.
007 */
008 package org.opengis.openoffice;
009
010 import com.sun.star.uno.XInterface;
011 import com.sun.star.beans.XPropertySet;
012
013
014 /**
015 * Services from the {@link org.opengis.referencing} package to be exported to
016 * <a href="http://www.openoffice.org">OpenOffice.org</a>.
017 *
018 * This interface is derived from the {@code XReferencing.idl} file using the {@code javamaker}
019 * tool provided in OpenOffice SDK, and disassembling the output using the {@code javap} tool
020 * provided in Java SDK. This source file exists mostly for javadoc purpose and in order to keep
021 * IDE happy. The {@code .class} file compiled from this source file <strong>must</strong> be
022 * overwritten by the {@code .class} file generated by {@code javamaker}.
023 *
024 * @author Martin Desruisseaux (IRD)
025 * @version 3.1
026 * @since 3.1
027 */
028 public interface XReferencing extends XInterface {
029 /**
030 * Returns the identified object description from an authority code.
031 *
032 * @param xOptions Provided by OpenOffice.
033 * @param authorityCode The code allocated by the authority.
034 * @return The identified object description, or {@code null}.
035 */
036 String getDescription(XPropertySet xOptions, String authorityCode);
037
038 /**
039 * Returns the scope for an identified object.
040 *
041 * @param xOptions Provided by OpenOffice.
042 * @param authorityCode The code allocated by the authority.
043 * @return The identified object scope, or {@code null}.
044 */
045 String getScope(XPropertySet xOptions, String authorityCode);
046
047 /**
048 * Returns the valid area as a textual description for an identified object.
049 *
050 * @param xOptions Provided by OpenOffice.
051 * @param authorityCode The code allocated by the authority.
052 * @return The identified object valid area, or {@code null}.
053 */
054 String getValidArea(XPropertySet xOptions, String authorityCode);
055
056 /**
057 * Returns the valid area as a geographic bounding box for an identified object. This method
058 * returns a 2×2 matrix. The first row contains the latitude and longitude of upper left
059 * corder, and the second row contains the latitude and longitude or bottom right corner. Units
060 * are degrees.
061 *
062 * @param xOptions Provided by OpenOffice.
063 * @param authorityCode The code allocated by the authority.
064 * @return The identified object bounding box, or {@code null}.
065 */
066 double[][] getBoundingBox(XPropertySet xOptions, String authorityCode);
067
068 /**
069 * Returns the remarks for an identified object.
070 *
071 * @param xOptions Provided by OpenOffice.
072 * @param authorityCode The code allocated by the authority.
073 * @return The identified object remarks, or {@code null}.
074 */
075 String getRemarks(XPropertySet xOptions, String authorityCode);
076
077 /**
078 * Returns the axis name for the specified dimension in an identified object.
079 *
080 * @param xOptions Provided by OpenOffice.
081 * @param authorityCode The code allocated by the authority.
082 * @param dimension The dimension (1, 2, ...).
083 * @return The name of the given axis, or {@code null}.
084 */
085 String getAxis(XPropertySet xOptions, String authorityCode, int dimension);
086
087 /**
088 * Returns the value for a coordinate reference system parameter.
089 *
090 * @param xOptions Provided by OpenOffice.
091 * @param authorityCode The code allocated by the authority.
092 * @param parameter The parameter name (e.g. "False easting").
093 * @return The value of the given parameter, or {@code null}.
094 */
095 Object getParameter(XPropertySet xOptions, String authorityCode, String parameter);
096
097 /**
098 * Returns the Well Know Text (WKT) for an identified object.
099 *
100 * @param xOptions Provided by OpenOffice.
101 * @param authorityCode The code allocated by the authority.
102 * @param authority The authority name for choice of parameter names. Usually "OGC".
103 * @return The identified object WKT, or {@code null}.
104 */
105 String getWKT(XPropertySet xOptions, String authorityCode, Object authority);
106
107 /**
108 * Returns the Well Know Text (WKT) of a transformation between two coordinate reference
109 * systems.
110 *
111 * @param xOptions Provided by OpenOffice.
112 * @param sourceCRS The authority code for the source coordinate reference system.
113 * @param targetCRS The authority code for the target coordinate reference system.
114 * @param authority The authority name for choice of parameter names. Usually "OGC".
115 * @return The transform WKT, or {@code null}.
116 */
117 String getTransformWKT(XPropertySet xOptions, String sourceCRS, String targetCRS, Object authority);
118
119 /**
120 * Returns the accuracy of a transformation between two coordinate reference systems.
121 *
122 * @param xOptions Provided by OpenOffice.
123 * @param sourceCRS The authority code for the source coordinate reference system.
124 * @param targetCRS The authority code for the target coordinate reference system.
125 * @return The transformation accuracy, or {@code null}.
126 */
127 double getAccuracy(XPropertySet xOptions, String sourceCRS, String targetCRS);
128
129 /**
130 * Transforms coordinates from the specified source CRS to the specified target CRS.
131 *
132 * @param xOptions Provided by OpenOffice.
133 * @param coordinates The coordinates to transform.
134 * @param sourceCRS The authority code for the source coordinate reference system.
135 * @param targetCRS The authority code for the target coordinate reference system.
136 * @return The transformed coordinates.
137 */
138 double[][] getTransformedCoordinates(XPropertySet xOptions, double[][] coordinates,
139 String sourceCRS, String targetCRS);
140 }