Package oracle.spatial.geometry
Class CoordSysInfo
- java.lang.Object
-
- oracle.spatial.geometry.CoordSysInfo
-
- All Implemented Interfaces:
java.io.Serializable
public class CoordSysInfo extends java.lang.Object implements java.io.SerializableImmutable, thread-safe class that stores simplified coordinate system information.Spherical coordinate systems return an inverse flattening of POSITIVE_INFINITY. Projected coordinate systems return NaN for semi-major axis and inverse flattening.
This class knows the geodetic coordinate systems distributed with the Oracle database; any other SRID is treated as projected by default.
SRID values can be customized before first use, overriding the database defaults. Once used, the definition of a SRID can not be changed.
- Since:
- 12.2
- See Also:
- Serialized Form
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static CoordSysInfocreateCoordSysInfo(int srid)Define a SRID to be a projected coordinate system, overriding the default values.static CoordSysInfocreateCoordSysInfo(int srid, double smax, double iflat)Define a SRID to be a geodetic coordinate system (longitude/latitude), overriding the default values.doubledefaultTolerance()Returns a suitable tolerance for use with this coordinate system.booleanequals(java.lang.Object obj)static CoordSysInfogetCoordsys(int srid)Return the CoordSysInfo for the given SRID.inthashCode()doubleiflat()booleanisGeodetic()protected java.lang.ObjectreadResolve()doublesmax()intsrid()
-
-
-
Method Detail
-
srid
public int srid()
-
isGeodetic
public boolean isGeodetic()
-
smax
public double smax()
-
iflat
public double iflat()
-
defaultTolerance
public double defaultTolerance()
Returns a suitable tolerance for use with this coordinate system.- Returns:
- an appropriate tolerance value.
-
createCoordSysInfo
public static CoordSysInfo createCoordSysInfo(int srid)
Define a SRID to be a projected coordinate system, overriding the default values. SRIDs can not be changed after definition. Definition must happen before first use of the SRID. SRID 0 can not be changed.- Parameters:
srid- SRID of projected coordinate system.- Returns:
- the defined coordinate system (also remembered internally)
-
createCoordSysInfo
public static CoordSysInfo createCoordSysInfo(int srid, double smax, double iflat)
Define a SRID to be a geodetic coordinate system (longitude/latitude), overriding the default values. SRIDs can not be changed after definition. Definition must happen before first use of the SRID. SRID 0 can not be changed.- Parameters:
srid- SRID of a geodetic coordinate system.smax- semi-major axis of ellipsoidiflat- inverse flattening- Returns:
- the defined coordinate system (also remembered inernally)
-
getCoordsys
public static CoordSysInfo getCoordsys(int srid)
Return the CoordSysInfo for the given SRID.- Parameters:
srid- the SRID to search for- Returns:
- coordinate system information
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
readResolve
protected java.lang.Object readResolve() throws java.io.ObjectStreamException- Throws:
java.io.ObjectStreamException
-
-