Class Wrapper
- java.lang.Object
-
- org.locationtech.proj4j.geoapi.Wrapper
-
- All Implemented Interfaces:
org.opengis.metadata.Identifier,org.opengis.referencing.ReferenceIdentifier
- Direct Known Subclasses:
AbstractCRS,AuthorityFactoryWrapper,Axis,DatumWrapper,EllipsoidWrapper,IdentifierEPSG,OperationFactoryWrapper,OperationMethodWrapper,ParameterAccessor,ParameterWrapper,PositionWrapper,PrimeMeridianWrapper,TransformWrapper
abstract class Wrapper extends java.lang.Object implements org.opengis.referencing.ReferenceIdentifierBase class for wrappers around PROJ4J implementations. Subclasses should return the object name in thegetCode()method.
-
-
Field Summary
Fields Modifier and Type Field Description (package private) static intBIDIMENSIONALThe default number of dimensions of the CRS.(package private) static intTRIDIMENSIONALThe number of dimensions when a non-NaN z coordinate value is provided.
-
Constructor Summary
Constructors Constructor Description Wrapper()Creates a new wrapper.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object other)Compares this wrapper with the given object for equality.java.util.Collection<org.opengis.util.GenericName>getAlias(){@return other names of this object}.org.opengis.metadata.citation.CitationgetAuthority(){@return the authority that defines this object}.abstract java.lang.StringgetCode(){@return the primary object name}.java.lang.StringgetCodeSpace(){@return a short name of the authority used as a code space}.org.opengis.metadata.extent.ExtentgetDomainOfValidity(){@return the domain of validity of this object}.java.util.Set<org.opengis.referencing.ReferenceIdentifier>getIdentifiers(){@return all identifiers (usually EPSG codes) of this object}.org.opengis.referencing.ReferenceIdentifiergetName(){@return the primary object name}.org.opengis.util.InternationalStringgetRemarks(){@return optional remarks about this object}.org.opengis.util.InternationalStringgetScope(){@return the scope of usage of this object}.java.lang.StringgetVersion(){@return the version of the defined object}.inthashCode(){@return a hash code value for this wrapper}.(package private) abstract java.lang.Objectimplementation(){@return the wrapped implementation}.java.lang.StringtoString(){@return the string representation of the wrapped PROJ4J object}.java.lang.StringtoWKT(){@return a WKT representation of this object}.
-
-
-
Field Detail
-
BIDIMENSIONAL
static final int BIDIMENSIONAL
The default number of dimensions of the CRS.- See Also:
- Constant Field Values
-
TRIDIMENSIONAL
static final int TRIDIMENSIONAL
The number of dimensions when a non-NaN z coordinate value is provided.- See Also:
- Constant Field Values
-
-
Method Detail
-
implementation
abstract java.lang.Object implementation()
{@return the wrapped implementation}.
-
getAuthority
public org.opengis.metadata.citation.Citation getAuthority()
{@return the authority that defines this object}. The default implementation assumes that there is none.- Specified by:
getAuthorityin interfaceorg.opengis.metadata.Identifier
-
getCodeSpace
public java.lang.String getCodeSpace()
{@return a short name of the authority used as a code space}. The default implementation returns "PROJ4J" on the assumption that the names are specific to PROJ4J. This is not completely true since those names are often derived from EPSG, but we don't really have a guarantee that they are exact or that PROJ4J didn't added their own definitions.- Specified by:
getCodeSpacein interfaceorg.opengis.referencing.ReferenceIdentifier
-
getVersion
public java.lang.String getVersion()
{@return the version of the defined object}. The default implementation assumes that there is none.- Specified by:
getVersionin interfaceorg.opengis.referencing.ReferenceIdentifier
-
getCode
public abstract java.lang.String getCode()
{@return the primary object name}. In the EPSG database, this is usually the long name.- Specified by:
getCodein interfaceorg.opengis.metadata.Identifier
-
getName
public final org.opengis.referencing.ReferenceIdentifier getName()
{@return the primary object name}. This method returnsthis, with the expectation that users will follow withgetCode(). Subclasses shall return the actual object name ingetCode().This is a method declared in the
IdentifiedObjectinterface. It is implemented in this base class for the convenience of subclasses that indirectly implementIdentifiedObject.
-
getAlias
public java.util.Collection<org.opengis.util.GenericName> getAlias()
{@return other names of this object}. In the EPSG database, this is usually the short name. The default implementation assumes that there is none.This is a method declared in the
IdentifiedObjectinterface. It is implemented in this base class for the convenience of subclasses that indirectly implementIdentifiedObject.
-
getIdentifiers
public java.util.Set<org.opengis.referencing.ReferenceIdentifier> getIdentifiers()
{@return all identifiers (usually EPSG codes) of this object}. The default implementation assumes that there is none.This is a method declared in the
IdentifiedObjectinterface. It is implemented in this base class for the convenience of subclasses that indirectly implementIdentifiedObject.
-
getScope
public org.opengis.util.InternationalString getScope()
{@return the scope of usage of this object}. If unknown, ISO 19111 requires that we return "not known".This method is not declared directly in the
IdentifiedObjectinterface, but appears in datum and coordinate operation sub-interfaces.
-
getDomainOfValidity
public org.opengis.metadata.extent.Extent getDomainOfValidity()
{@return the domain of validity of this object}. The default implementation assumes that there is none.This method is not declared directly in the
IdentifiedObjectinterface, but appears in datum and coordinate operation sub-interfaces.
-
getRemarks
public org.opengis.util.InternationalString getRemarks()
{@return optional remarks about this object}. The default implementation assumes that there is none.This is a method declared in the
IdentifiedObjectinterface. It is implemented in this base class for the convenience of subclasses that indirectly implementIdentifiedObject.
-
toWKT
public java.lang.String toWKT() throws java.lang.UnsupportedOperationException{@return a WKT representation of this object}. The default implementation assumes that there is none.This is a method declared in the
IdentifiedObjectinterface. It is implemented in this base class for the convenience of subclasses that indirectly implementIdentifiedObject.- Throws:
java.lang.UnsupportedOperationException
-
toString
public java.lang.String toString()
{@return the string representation of the wrapped PROJ4J object}.- Overrides:
toStringin classjava.lang.Object
-
hashCode
public final int hashCode()
{@return a hash code value for this wrapper}.- Overrides:
hashCodein classjava.lang.Object
-
equals
public final boolean equals(java.lang.Object other)
Compares this wrapper with the given object for equality. This method returnstrueif the two objects are wrappers of the same class wrapping equal PROJ4 implementations.- Overrides:
equalsin classjava.lang.Object
-
-