Class MultiAuthoritiesFactory
- All Implemented Interfaces:
org.opengis.referencing.AuthorityFactory
,org.opengis.referencing.crs.CRSAuthorityFactory
,org.opengis.referencing.cs.CSAuthorityFactory
,org.opengis.referencing.datum.DatumAuthorityFactory
,org.opengis.referencing.operation.CoordinateOperationAuthorityFactory
,org.opengis.util.Factory
This factory requires that every codes given to a createFoo(String)
method are prefixed by a namespace,
for example "EPSG:4326"
or "EPSG::4326"
.
When a createFoo(String)
method is invoked, this class uses the authority part in the
“authority:code” argument for locating a factory capable to create a geodetic object
for the code part. If a factory is found in the list of factories given at construction time,
then the work is delegated to that factory. Otherwise a NoSuchAuthorityFactoryException
is thrown.
URI syntax
This factory can also parse URNs or URLs of the following forms:"urn:ogc:def:
type:
authority:
version:
code"
"http://www.opengis.net/def/
type/
authority/
version/
code"
"http://www.opengis.net/gml/srs/
authority.xml#
code"
MultiAuthoritiesFactory
uses the type information in the URN only for
delegating to a more specific method, never for delegating to a less specific method.
An exception will be thrown if the type in the URN is incompatible with the invoked method.
createObject("urn:ogc:def:crs:EPSG::4326")
is invoked,
then MultiAuthoritiesFactory
will delegate (indirectly, ignoring caching for this example) the object
creation to EPSGDataAccess.createCoordinateReferenceSystem(String)
instead of EPSGDataAccess.createObject(String)
because of the
"crs"
part in the URN. The more specific method gives better performances and avoid ambiguities."urn:ogc:def:
type,
type₁:
authority₁:
version₁:
code₁,
type₂:
authority₂:
version₂:
code₂"
"http://www.opengis.net/def/crs-compound?
1=http://www.opengis.net/def/crs/
authority₁/
version₁/
code₁&
2=http://www.opengis.net/def/crs/
authority₂/
version₂/
code₂"
MultiAuthoritiesFactory
invokes createObject(String)
for each component
and combines the result as described by the CRS.compound(CoordinateReferenceSystem...)
method.
URNs (but not URLs) can also combine a
geodetic datum with an
ellipsoidal coordinate system for creating a new
geographic CRS, or a base geographic CRS with a
conversion and a
Cartesian coordinate system for creating a new
projected coordinate reference system, or
coordinate operations
for creating a concatenated operation.
Multiple versions for the same authority
MultiAuthoritiesFactory
accepts an arbitrary number of factories for the same authority, provided that
those factories have different version numbers. If a createFoo(String)
method is invoked with a URN
containing a version number different than zero, then MultiAuthoritiesFactory
will search for a factory
with that exact version, or throw a NoSuchAuthorityFactoryException
if no suitable factory is found.
If a createFoo(String)
method is invoked with the version number omitted, then MultiAuthoritiesFactory
will use the first factory in iteration order for the requested authority regardless of its version number.
MultiAuthoritiesFactory
instance could contain two EPSGFactory
instances:
one for version 8.2 and another one for version 7.9 of the EPSG dataset.
A specific version can be requested in the URN given to createFoo(String)
methods,
for example "urn:ogc:def:crs:EPSG:8.2:4326"
.
If no version is given of if the given version is zero,
then the first EPSG factory in iteration order is used regardless of its version number.
Multi-threading
This class is thread-safe if all delegate factories are themselves thread-safe. However, the factory providers, which are given to the constructor asIterable
instances,
do not need to be thread-safe. See constructor Javadoc for more information.- Since:
- 0.7
- Version:
- 1.2
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static final class
A proxy that does not execute immediately thecreate
method on a factory, but instead stores information for later execution.private static class
AIdentifiedObjectFinder
which tests every factories declared in the collection of factories. -
Field Summary
FieldsModifier and TypeFieldDescriptionThe code spaces of all factories given to the constructor, created when first requested.private final ConcurrentMap
<AuthorityFactoryIdentifier, org.opengis.referencing.AuthorityFactory> The factories obtained fromgetAuthorityFactory(Class, String, String)
and similar methods.private final AtomicInteger
A bit masks identifying which providers have given us all their factories.private boolean
Whether this factory should relax some rules when processing a given authority code.private final Iterable<? extends org.opengis.referencing.AuthorityFactory>[]
The factory providers given at construction time.private final Map
<AuthorityFactoryIdentifier, Boolean> The factories for which we have logged a warning. -
Constructor Summary
ConstructorsConstructorDescriptionMultiAuthoritiesFactory
(Iterable<? extends org.opengis.referencing.crs.CRSAuthorityFactory> crsFactories, Iterable<? extends org.opengis.referencing.cs.CSAuthorityFactory> csFactories, Iterable<? extends org.opengis.referencing.datum.DatumAuthorityFactory> datumFactories, Iterable<? extends org.opengis.referencing.operation.CoordinateOperationAuthorityFactory> copFactories) Creates a new multi-factories instance using the given lists of factories. -
Method Summary
Modifier and TypeMethodDescriptionprivate void
applyAndMask
(int mask) SetsisIterationCompleted
toiterationCompleted & mask
.private org.opengis.referencing.AuthorityFactory
cache
(AuthorityFactoryIdentifier identifier, org.opengis.referencing.AuthorityFactory factory) Caches the given factory, but without replacing existing instance if any.private boolean
canLog
(AuthorityFactoryIdentifier identifier) Returnstrue
if thisMultiAuthoritiesFactory
can log a warning for the given factory.private <T> T
combine
(Class<T> type, DefinitionURI[] references, boolean isHTTP) Invoked when acreateFoo(…)
method is given a combined URI.private static org.opengis.referencing.crs.GeneralDerivedCRS
combine
(org.opengis.referencing.crs.CoordinateReferenceSystem baseCRS, org.opengis.referencing.operation.Conversion fromBase, org.opengis.referencing.cs.CoordinateSystem cs) Invoked when acreateFoo(…)
method is given a combined URI containing a conversion and a coordinate system.private static org.opengis.referencing.crs.GeodeticCRS
combine
(org.opengis.referencing.datum.GeodeticDatum datum, org.opengis.referencing.cs.CoordinateSystem cs) Invoked when acreateFoo(…)
method is given a combined URI containing a datum and a coordinate system.private <T> T
create
(AuthorityFactoryProxy<? extends T> proxy, String code) Creates an object from a code using the given proxy.org.opengis.referencing.cs.CartesianCS
createCartesianCS
(String code) Creates a 2- or 3-dimensional Cartesian coordinate system made of straight orthogonal axes.org.opengis.referencing.crs.CompoundCRS
createCompoundCRS
(String code) Creates a CRS describing the position of points through two or more independent coordinate reference systems.org.opengis.referencing.operation.CoordinateOperation
Creates an operation for transforming coordinates in the source CRS to coordinates in the target CRS.org.opengis.referencing.crs.CoordinateReferenceSystem
Creates an arbitrary coordinate reference system from a code.org.opengis.referencing.cs.CoordinateSystem
createCoordinateSystem
(String code) Creates an arbitrary coordinate system from a code.org.opengis.referencing.cs.CoordinateSystemAxis
Creates a coordinate system axis with name, direction, unit and range of values.org.opengis.referencing.cs.CylindricalCS
createCylindricalCS
(String code) Creates a 3-dimensional coordinate system made of a polar coordinate system extended by a straight perpendicular axis.org.opengis.referencing.datum.Datum
createDatum
(String code) Creates an arbitrary datum from a code.org.opengis.referencing.crs.DerivedCRS
createDerivedCRS
(String code) Creates a CRS that is defined by its coordinate conversion from another CRS (not by a datum).org.opengis.referencing.datum.Ellipsoid
createEllipsoid
(String code) Creates a geometric figure that can be used to describe the approximate shape of the earth.org.opengis.referencing.cs.EllipsoidalCS
createEllipsoidalCS
(String code) Creates a 2- or 3-dimensional coordinate system for geodetic latitude and longitude, sometimes with ellipsoidal height.org.opengis.referencing.crs.EngineeringCRS
createEngineeringCRS
(String code) Creates a 1-, 2- or 3-dimensional contextually local coordinate reference system.org.opengis.referencing.datum.EngineeringDatum
createEngineeringDatum
(String code) Creates a datum defining the origin of an engineering coordinate reference system.org.opengis.metadata.extent.Extent
createExtent
(String code) Creates information about spatial, vertical, and temporal extent (usually a domain of validity) from a code.Set
<org.opengis.referencing.operation.CoordinateOperation> createFromCoordinateReferenceSystemCodes
(String sourceCRS, String targetCRS) Creates operations from source and target coordinate reference system codes.org.opengis.referencing.crs.GeocentricCRS
createGeocentricCRS
(String code) Creates a 3-dimensional coordinate reference system with the origin at the approximate centre of mass of the earth.org.opengis.referencing.datum.GeodeticDatum
createGeodeticDatum
(String code) Creates a datum defining the location and orientation of an ellipsoid that approximates the shape of the earth.org.opengis.referencing.crs.GeographicCRS
createGeographicCRS
(String code) Creates a 2- or 3-dimensional coordinate reference system based on an ellipsoidal approximation of the geoid.org.opengis.referencing.crs.ImageCRS
createImageCRS
(String code) Creates a 2-dimensional engineering coordinate reference system applied to locations in images.org.opengis.referencing.datum.ImageDatum
createImageDatum
(String code) Creates a datum defining the origin of an image coordinate reference system.org.opengis.referencing.IdentifiedObject
createObject
(String code) Creates an arbitrary object from a code.org.opengis.referencing.operation.OperationMethod
createOperationMethod
(String code) Creates a description of the algorithm and parameters used to perform a coordinate operation.org.opengis.parameter.ParameterDescriptor
<?> Creates a definition of a single parameter used by an operation method.org.opengis.referencing.cs.PolarCS
createPolarCS
(String code) Creates a 2-dimensional coordinate system for coordinates represented by a distance from the origin and an angle from a fixed direction.org.opengis.referencing.datum.PrimeMeridian
createPrimeMeridian
(String code) Creates a prime meridian defining the origin from which longitude values are determined.org.opengis.referencing.crs.ProjectedCRS
createProjectedCRS
(String code) Creates a 2-dimensional coordinate reference system used to approximate the shape of the earth on a planar surface.org.opengis.referencing.cs.SphericalCS
createSphericalCS
(String code) Creates a 3-dimensional coordinate system with one distance measured from the origin and two angular coordinates.org.opengis.referencing.crs.TemporalCRS
createTemporalCRS
(String code) Creates a 1-dimensional coordinate reference system used for the recording of time.org.opengis.referencing.datum.TemporalDatum
createTemporalDatum
(String code) Creates a datum defining the origin of a temporal coordinate reference system.org.opengis.referencing.cs.TimeCS
createTimeCS
(String code) Creates a 1-dimensional coordinate system for heights or depths of points.javax.measure.Unit
<?> createUnit
(String code) Creates an unit of measurement from a code.org.opengis.referencing.crs.VerticalCRS
createVerticalCRS
(String code) Creates a 1-dimensional coordinate reference system used for recording heights or depths.org.opengis.referencing.cs.VerticalCS
createVerticalCS
(String code) Creates a 1-dimensional coordinate system for heights or depths of points.org.opengis.referencing.datum.VerticalDatum
createVerticalDatum
(String code) Creates a datum identifying a particular reference level surface used as a zero-height surface.(package private) final Iterator
<org.opengis.referencing.AuthorityFactory> Returns an iterator over all factories in thisMultiAuthoritiesFactory
.org.opengis.metadata.citation.Citation
Returns the database or specification that defines the codes recognized by this factory.getAuthorityCodes
(Class<? extends org.opengis.referencing.IdentifiedObject> type) Returns the set of authority codes for objects of the given type.final <T extends org.opengis.referencing.AuthorityFactory>
TgetAuthorityFactory
(Class<T> type, String authority, String version) Returns the factory identified by the given type, authority and version.private org.opengis.referencing.AuthorityFactory
Returns the factory identified by the given type, authority and version.(package private) static String
getCodeSpace
(org.opengis.referencing.AuthorityFactory factory) Returns the "main" namespace of the given factory, ornull
if none.Returns the code spaces of all factories given to the constructor.getCodeSpaces
(org.opengis.referencing.AuthorityFactory factory) Returns the code spaces for the given factory.org.opengis.util.InternationalString
getDescriptionText
(String code) Returns a description of the object corresponding to a code.boolean
Returns whether this factory should relax some rules when processing a given authority code.Creates a finder which can be used for looking up unidentified objects.void
reload()
Clears the cache and notifies thisMultiAuthoritiesFactory
that all factories will need to be fetched again from the providers given at construction time.private static <T> T
remove
(DefinitionURI[] references, org.opengis.referencing.IdentifiedObject[] components, Class<T> type) If the giventype
is found in the givenreferences
, sets that reference element tonull
and returns the correspondingcomponents
element.void
setLenient
(boolean lenient) Sets whether this factory should relax some rules when processing a given code.Methods inherited from class org.apache.sis.referencing.factory.GeodeticAuthorityFactory
appendStringTo, createParametricCRS, createParametricCS, createParametricDatum, regionMatches, toString, trimNamespace
Methods inherited from class org.apache.sis.util.iso.AbstractFactory
getVendor
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.opengis.util.Factory
getVendor
-
Field Details
-
providers
The factory providers given at construction time. Elements in the array are forCRSAuthorityFactory
,CSAuthorityFactory
,DatumAuthorityFactory
andCoordinateOperationAuthorityFactory
in that order. That order is defined by the constant values inAuthorityFactoryIdentifier
.Note that this array is shorter than the amount of
AuthorityFactoryIdentifier
values. The lastAuthorityFactoryIdentifier
values are handled in a special way.The array may contain
null
elements when there is no provider for a given type. Content of this array shall be immutable after construction time in order to avoid the need for synchronization when reading the array. However, usage of anIterable
element shall be synchronized on thatIterable
. -
factories
private final ConcurrentMap<AuthorityFactoryIdentifier,org.opengis.referencing.AuthorityFactory> factoriesThe factories obtained fromgetAuthorityFactory(Class, String, String)
and similar methods. -
isIterationCompleted
A bit masks identifying which providers have given us all their factories. The value(1 << type)
is set whenMultiAuthoritiesFactory
has iterated until the end ofproviders[type].iterator()
. -
codeSpaces
The code spaces of all factories given to the constructor, created when first requested.- See Also:
-
isLenient
private volatile boolean isLenientWhether this factory should relax some rules when processing a given authority code. SeeisLenient()
javadoc for a description of relaxed rules.- See Also:
-
warnings
The factories for which we have logged a warning. This is used in order to avoid logging the same warnings many time. We do not bother using a concurrent map here since this map should be rarely used.
-
-
Constructor Details
-
MultiAuthoritiesFactory
public MultiAuthoritiesFactory(Iterable<? extends org.opengis.referencing.crs.CRSAuthorityFactory> crsFactories, Iterable<? extends org.opengis.referencing.cs.CSAuthorityFactory> csFactories, Iterable<? extends org.opengis.referencing.datum.DatumAuthorityFactory> datumFactories, Iterable<? extends org.opengis.referencing.operation.CoordinateOperationAuthorityFactory> copFactories) Creates a new multi-factories instance using the given lists of factories. Calls tocreateFoo(String)
methods will scan the supplied factories in their iteration order when first needed. The first factory having the requested namespace will be used.Requirements
MultiAuthoritiesFactory
may iterate over the sameIterable
more than once. Each iteration shall return the same instances than previous iterations, unlessreload()
has been invoked.The
Iterable
s do not need to be thread-safe.MultiAuthoritiesFactory
will use them only in blocks synchronized on theIterable
instance. For example, all usages ofcrsFactory
will be done inside asynchronized(crsFactory)
block.Name collision
If anIterable
contains more than one factory for the same namespace and version, then only the first occurrence will be used. All additional factories for the same namespace and version will be ignored, after a warning has been logged.Caching
MultiAuthoritiesFactory
caches the factories found from the givenIterable
s, but does not cache the objects created by those factories. This constructor assumes that the given factories already do their own caching.- Parameters:
crsFactories
- the factories for creatingCoordinateReferenceSystem
objects, or null if none.csFactories
- the factories for creatingCoordinateSystem
objects, or null if none.datumFactories
- the factories for creatingDatum
objects, or null if none.copFactories
- the factories for creatingCoordinateOperation
objects, or null if none.
-
-
Method Details
-
isLenient
public boolean isLenient()Returns whether this factory should relax some rules when processing a given authority code. If this value istrue
, then the behavior of thisMultiAuthoritiesFactory
is changed as below:- If a version is specified in a URN but there is no factory for that specific version, then fallback on a factory for the same authority but the default version.
false
, which means that an exception will be thrown if there is no factory specifically for the requested version.- Returns:
- whether this factory should relax some rules when processing a given authority code.
-
setLenient
public void setLenient(boolean lenient) Sets whether this factory should relax some rules when processing a given code.- Parameters:
lenient
- whether this factory should relax some rules when processing a given authority code.
-
getAuthority
public org.opengis.metadata.citation.Citation getAuthority()Returns the database or specification that defines the codes recognized by this factory. The default implementation returnsnull
sinceMultiAuthoritiesFactory
is not about a particular authority.- Specified by:
getAuthority
in interfaceorg.opengis.referencing.AuthorityFactory
- Specified by:
getAuthority
in classGeodeticAuthorityFactory
- Returns:
- the organization responsible for definition of the database, or
null
if unknown. - See Also:
-
getAuthorityCodes
public Set<String> getAuthorityCodes(Class<? extends org.opengis.referencing.IdentifiedObject> type) throws org.opengis.util.FactoryException Returns the set of authority codes for objects of the given type. This method returns the union of codes returned by all factories specified at construction time.The
Set.contains(Object)
method of the returned set is lenient: it accepts various ways to format a code even if the iterator returns only one form. For example, thecontains(Object)
method may returntrue
for"EPSG:4326"
,"EPSG::4326"
,"urn:ogc:def:crs:EPSG::4326"
, etc. even if the iterator returns only"EPSG:4326"
.Warnings:
- Callers should not retain a reference to the returned collection for a long time, since it may be backed by database connections (depending on the factory implementations).
- The returned set is not thread-safe. Each thread should ask its own instance and let the garbage collector disposes it as soon as the collection is not needed anymore.
- Call to the
Set.size()
method on the returned collection should be avoided since it may be costly.
- Specified by:
getAuthorityCodes
in interfaceorg.opengis.referencing.AuthorityFactory
- Parameters:
type
- the spatial reference objects type.- Returns:
- the set of authority codes for spatial reference objects of the given type.
- Throws:
org.opengis.util.FactoryException
- if access to an underlying factory failed.
-
getCodeSpaces
Returns the code spaces of all factories given to the constructor.Implementation note: the current implementation may be relatively costly since it implies instantiation of all factories.- Overrides:
getCodeSpaces
in classGeodeticAuthorityFactory
- Returns:
- the code spaces of all factories.
-
getCodeSpaces
Returns the code spaces for the given factory. This method delegates toGeodeticAuthorityFactory.getCodeSpaces()
if possible, or reproduces its default implementation otherwise. -
getCodeSpace
Returns the "main" namespace of the given factory, ornull
if none. Current implementation returns the first namespace, but this may be changed in any future SIS version.The purpose of this method is to get a unique identifier of a factory, ignoring version number.
-
cache
private org.opengis.referencing.AuthorityFactory cache(AuthorityFactoryIdentifier identifier, org.opengis.referencing.AuthorityFactory factory) Caches the given factory, but without replacing existing instance if any. This method returns the factory that we should use, either the given instance of the cached one.- Parameters:
identifier
- the type, authority and version of the factory to cache.factory
- the factory to cache.- Returns:
- the given
factory
if no previous instance was cached, or the existing instance otherwise.
-
getAllFactories
Returns an iterator over all factories in thisMultiAuthoritiesFactory
. Note that the same factory instance may be returned more than once if it implements more than one of theCRSAuthorityFactory
,CSAuthorityFactory
,DatumAuthorityFactory
orCoordinateOperationAuthorityFactory
interfaces.This iterator takes care of synchronization on the
Iterable<AuthorityFactory>
instances. Note that despite the above-cited synchronization, the returned iterator is not thread-safe: each thread needs to use its own iterator instance. However, provided that the above condition is met, threads can safely use their iterators concurrently. -
getAuthorityFactory
public final <T extends org.opengis.referencing.AuthorityFactory> T getAuthorityFactory(Class<T> type, String authority, String version) throws NoSuchAuthorityFactoryException Returns the factory identified by the given type, authority and version.- Type Parameters:
T
- the compile-time value oftype
.- Parameters:
type
- the type of the desired factory as one of theCRSAuthorityFactory
,CSAuthorityFactory
,DatumAuthorityFactory
orCoordinateOperationFactory
interfaces.authority
- the namespace or authority identifier of the desired factory. Examples:"EPSG"
,"CRS"
or"AUTO2"
.version
- the version of the desired factory, ornull
for the default version.- Returns:
- the factory for the given type, authority and version.
- Throws:
NoSuchAuthorityFactoryException
- if no suitable factory has been found.
-
getAuthorityFactory
private org.opengis.referencing.AuthorityFactory getAuthorityFactory(AuthorityFactoryIdentifier request) throws NoSuchAuthorityFactoryException Returns the factory identified by the given type, authority and version. If no such factory is found in the cache, then this method iterates over the factories created by the providers given at construction time.- Parameters:
request
- the type, authority and version of the desired factory.- Returns:
- the factory for the given type, authority and version.
- Throws:
NoSuchAuthorityFactoryException
- if no suitable factory has been found.
-
canLog
Returnstrue
if thisMultiAuthoritiesFactory
can log a warning for the given factory. -
create
private <T> T create(AuthorityFactoryProxy<? extends T> proxy, String code) throws org.opengis.util.FactoryException Creates an object from a code using the given proxy.- Type Parameters:
T
- the type of the object to be returned.- Parameters:
proxy
- the proxy to use for creating the object.code
- the code of the object to create.- Returns:
- the object from one of the authority factory specified at construction time.
- Throws:
org.opengis.util.FactoryException
- if an error occurred while creating the object.
-
getDescriptionText
public org.opengis.util.InternationalString getDescriptionText(String code) throws org.opengis.util.FactoryException Returns a description of the object corresponding to a code. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:
type:
authority:
version:
codehttp://www.opengis.net/def/
type/
authority/
version/
codehttp://www.opengis.net/gml/srs/
authority.xml#
code
- Specified by:
getDescriptionText
in interfaceorg.opengis.referencing.AuthorityFactory
- Overrides:
getDescriptionText
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- a description of the object, or
null
if the object corresponding to the specifiedcode
has no description. - Throws:
org.opengis.util.FactoryException
- if an error occurred while fetching the description.
- authority
-
createObject
public org.opengis.referencing.IdentifiedObject createObject(String code) throws org.opengis.util.FactoryException Creates an arbitrary object from a code. The given code can use any of the following patterns, where version is optional:- authority
:
code — note that this form is ambiguous - authority
:
version:
code — note that this form is ambiguous urn:ogc:def:
type:
authority:
version:
codehttp://www.opengis.net/def/
type/
authority/
version/
codehttp://www.opengis.net/gml/srs/
authority.xml#
code
createObject(String)
method because different kinds of objects can have the same code.- Specified by:
createObject
in interfaceorg.opengis.referencing.AuthorityFactory
- Specified by:
createObject
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the object for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createCoordinateReferenceSystem
public org.opengis.referencing.crs.CoordinateReferenceSystem createCoordinateReferenceSystem(String code) throws org.opengis.util.FactoryException Creates an arbitrary coordinate reference system from a code. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:crs:
authority:
version:
codehttp://www.opengis.net/def/crs/
authority/
version/
codehttp://www.opengis.net/gml/srs/
authority.xml#
code
- Specified by:
createCoordinateReferenceSystem
in interfaceorg.opengis.referencing.crs.CRSAuthorityFactory
- Overrides:
createCoordinateReferenceSystem
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate reference system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createGeographicCRS
public org.opengis.referencing.crs.GeographicCRS createGeographicCRS(String code) throws org.opengis.util.FactoryException Creates a 2- or 3-dimensional coordinate reference system based on an ellipsoidal approximation of the geoid. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:crs:
authority:
version:
codehttp://www.opengis.net/def/crs/
authority/
version/
codehttp://www.opengis.net/gml/srs/
authority.xml#
code
- Specified by:
createGeographicCRS
in interfaceorg.opengis.referencing.crs.CRSAuthorityFactory
- Overrides:
createGeographicCRS
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate reference system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createGeocentricCRS
public org.opengis.referencing.crs.GeocentricCRS createGeocentricCRS(String code) throws org.opengis.util.FactoryException Creates a 3-dimensional coordinate reference system with the origin at the approximate centre of mass of the earth. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:crs:
authority:
version:
codehttp://www.opengis.net/def/crs/
authority/
version/
codehttp://www.opengis.net/gml/srs/
authority.xml#
code
- Specified by:
createGeocentricCRS
in interfaceorg.opengis.referencing.crs.CRSAuthorityFactory
- Overrides:
createGeocentricCRS
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate reference system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createProjectedCRS
public org.opengis.referencing.crs.ProjectedCRS createProjectedCRS(String code) throws org.opengis.util.FactoryException Creates a 2-dimensional coordinate reference system used to approximate the shape of the earth on a planar surface. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:crs:
authority:
version:
codehttp://www.opengis.net/def/crs/
authority/
version/
codehttp://www.opengis.net/gml/srs/
authority.xml#
code
- Specified by:
createProjectedCRS
in interfaceorg.opengis.referencing.crs.CRSAuthorityFactory
- Overrides:
createProjectedCRS
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate reference system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createVerticalCRS
public org.opengis.referencing.crs.VerticalCRS createVerticalCRS(String code) throws org.opengis.util.FactoryException Creates a 1-dimensional coordinate reference system used for recording heights or depths. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:crs:
authority:
version:
codehttp://www.opengis.net/def/crs/
authority/
version/
codehttp://www.opengis.net/gml/srs/
authority.xml#
code
- Specified by:
createVerticalCRS
in interfaceorg.opengis.referencing.crs.CRSAuthorityFactory
- Overrides:
createVerticalCRS
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate reference system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createTemporalCRS
public org.opengis.referencing.crs.TemporalCRS createTemporalCRS(String code) throws org.opengis.util.FactoryException Creates a 1-dimensional coordinate reference system used for the recording of time. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:crs:
authority:
version:
codehttp://www.opengis.net/def/crs/
authority/
version/
codehttp://www.opengis.net/gml/srs/
authority.xml#
code
- Specified by:
createTemporalCRS
in interfaceorg.opengis.referencing.crs.CRSAuthorityFactory
- Overrides:
createTemporalCRS
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate reference system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createCompoundCRS
public org.opengis.referencing.crs.CompoundCRS createCompoundCRS(String code) throws org.opengis.util.FactoryException Creates a CRS describing the position of points through two or more independent coordinate reference systems. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:crs:
authority:
version:
codehttp://www.opengis.net/def/crs/
authority/
version/
codehttp://www.opengis.net/gml/srs/
authority.xml#
code
- Specified by:
createCompoundCRS
in interfaceorg.opengis.referencing.crs.CRSAuthorityFactory
- Overrides:
createCompoundCRS
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate reference system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createDerivedCRS
public org.opengis.referencing.crs.DerivedCRS createDerivedCRS(String code) throws org.opengis.util.FactoryException Creates a CRS that is defined by its coordinate conversion from another CRS (not by a datum). The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:crs:
authority:
version:
codehttp://www.opengis.net/def/crs/
authority/
version/
codehttp://www.opengis.net/gml/srs/
authority.xml#
code
- Specified by:
createDerivedCRS
in interfaceorg.opengis.referencing.crs.CRSAuthorityFactory
- Overrides:
createDerivedCRS
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate reference system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createEngineeringCRS
public org.opengis.referencing.crs.EngineeringCRS createEngineeringCRS(String code) throws org.opengis.util.FactoryException Creates a 1-, 2- or 3-dimensional contextually local coordinate reference system. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:crs:
authority:
version:
codehttp://www.opengis.net/def/crs/
authority/
version/
codehttp://www.opengis.net/gml/srs/
authority.xml#
code
- Specified by:
createEngineeringCRS
in interfaceorg.opengis.referencing.crs.CRSAuthorityFactory
- Overrides:
createEngineeringCRS
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate reference system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createImageCRS
public org.opengis.referencing.crs.ImageCRS createImageCRS(String code) throws org.opengis.util.FactoryException Creates a 2-dimensional engineering coordinate reference system applied to locations in images. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:crs:
authority:
version:
codehttp://www.opengis.net/def/crs/
authority/
version/
codehttp://www.opengis.net/gml/srs/
authority.xml#
code
- Specified by:
createImageCRS
in interfaceorg.opengis.referencing.crs.CRSAuthorityFactory
- Overrides:
createImageCRS
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate reference system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createDatum
public org.opengis.referencing.datum.Datum createDatum(String code) throws org.opengis.util.FactoryException Creates an arbitrary datum from a code. The returned object will typically be an The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:datum:
authority:
version:
codehttp://www.opengis.net/def/datum/
authority/
version/
code
- Specified by:
createDatum
in interfaceorg.opengis.referencing.datum.DatumAuthorityFactory
- Overrides:
createDatum
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the datum for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createGeodeticDatum
public org.opengis.referencing.datum.GeodeticDatum createGeodeticDatum(String code) throws org.opengis.util.FactoryException Creates a datum defining the location and orientation of an ellipsoid that approximates the shape of the earth. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:datum:
authority:
version:
codehttp://www.opengis.net/def/datum/
authority/
version/
code
- Specified by:
createGeodeticDatum
in interfaceorg.opengis.referencing.datum.DatumAuthorityFactory
- Overrides:
createGeodeticDatum
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the datum for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createVerticalDatum
public org.opengis.referencing.datum.VerticalDatum createVerticalDatum(String code) throws org.opengis.util.FactoryException Creates a datum identifying a particular reference level surface used as a zero-height surface. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:datum:
authority:
version:
codehttp://www.opengis.net/def/datum/
authority/
version/
code
- Specified by:
createVerticalDatum
in interfaceorg.opengis.referencing.datum.DatumAuthorityFactory
- Overrides:
createVerticalDatum
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the datum for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createTemporalDatum
public org.opengis.referencing.datum.TemporalDatum createTemporalDatum(String code) throws org.opengis.util.FactoryException Creates a datum defining the origin of a temporal coordinate reference system. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:datum:
authority:
version:
codehttp://www.opengis.net/def/datum/
authority/
version/
code
- Specified by:
createTemporalDatum
in interfaceorg.opengis.referencing.datum.DatumAuthorityFactory
- Overrides:
createTemporalDatum
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the datum for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createEngineeringDatum
public org.opengis.referencing.datum.EngineeringDatum createEngineeringDatum(String code) throws org.opengis.util.FactoryException Creates a datum defining the origin of an engineering coordinate reference system. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:datum:
authority:
version:
codehttp://www.opengis.net/def/datum/
authority/
version/
code
- Specified by:
createEngineeringDatum
in interfaceorg.opengis.referencing.datum.DatumAuthorityFactory
- Overrides:
createEngineeringDatum
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the datum for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createImageDatum
public org.opengis.referencing.datum.ImageDatum createImageDatum(String code) throws org.opengis.util.FactoryException Creates a datum defining the origin of an image coordinate reference system. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:datum:
authority:
version:
codehttp://www.opengis.net/def/datum/
authority/
version/
code
- Specified by:
createImageDatum
in interfaceorg.opengis.referencing.datum.DatumAuthorityFactory
- Overrides:
createImageDatum
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the datum for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createEllipsoid
public org.opengis.referencing.datum.Ellipsoid createEllipsoid(String code) throws org.opengis.util.FactoryException Creates a geometric figure that can be used to describe the approximate shape of the earth. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:ellipsoid:
authority:
version:
codehttp://www.opengis.net/def/ellipsoid/
authority/
version/
code
- Specified by:
createEllipsoid
in interfaceorg.opengis.referencing.datum.DatumAuthorityFactory
- Overrides:
createEllipsoid
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the ellipsoid for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createPrimeMeridian
public org.opengis.referencing.datum.PrimeMeridian createPrimeMeridian(String code) throws org.opengis.util.FactoryException Creates a prime meridian defining the origin from which longitude values are determined. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:meridian:
authority:
version:
codehttp://www.opengis.net/def/meridian/
authority/
version/
code
- Specified by:
createPrimeMeridian
in interfaceorg.opengis.referencing.datum.DatumAuthorityFactory
- Overrides:
createPrimeMeridian
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the prime meridian for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createExtent
public org.opengis.metadata.extent.Extent createExtent(String code) throws org.opengis.util.FactoryException Creates information about spatial, vertical, and temporal extent (usually a domain of validity) from a code. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code
- Overrides:
createExtent
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the extent for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createCoordinateSystem
public org.opengis.referencing.cs.CoordinateSystem createCoordinateSystem(String code) throws org.opengis.util.FactoryException Creates an arbitrary coordinate system from a code. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:cs:
authority:
version:
codehttp://www.opengis.net/def/cs/
authority/
version/
code
- Specified by:
createCoordinateSystem
in interfaceorg.opengis.referencing.cs.CSAuthorityFactory
- Overrides:
createCoordinateSystem
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createEllipsoidalCS
public org.opengis.referencing.cs.EllipsoidalCS createEllipsoidalCS(String code) throws org.opengis.util.FactoryException Creates a 2- or 3-dimensional coordinate system for geodetic latitude and longitude, sometimes with ellipsoidal height. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:cs:
authority:
version:
codehttp://www.opengis.net/def/cs/
authority/
version/
code
- Specified by:
createEllipsoidalCS
in interfaceorg.opengis.referencing.cs.CSAuthorityFactory
- Overrides:
createEllipsoidalCS
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createVerticalCS
public org.opengis.referencing.cs.VerticalCS createVerticalCS(String code) throws org.opengis.util.FactoryException Creates a 1-dimensional coordinate system for heights or depths of points. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:cs:
authority:
version:
codehttp://www.opengis.net/def/cs/
authority/
version/
code
- Specified by:
createVerticalCS
in interfaceorg.opengis.referencing.cs.CSAuthorityFactory
- Overrides:
createVerticalCS
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createTimeCS
public org.opengis.referencing.cs.TimeCS createTimeCS(String code) throws org.opengis.util.FactoryException Creates a 1-dimensional coordinate system for heights or depths of points. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:cs:
authority:
version:
codehttp://www.opengis.net/def/cs/
authority/
version/
code
- Specified by:
createTimeCS
in interfaceorg.opengis.referencing.cs.CSAuthorityFactory
- Overrides:
createTimeCS
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createCartesianCS
public org.opengis.referencing.cs.CartesianCS createCartesianCS(String code) throws org.opengis.util.FactoryException Creates a 2- or 3-dimensional Cartesian coordinate system made of straight orthogonal axes. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:cs:
authority:
version:
codehttp://www.opengis.net/def/cs/
authority/
version/
code
- Specified by:
createCartesianCS
in interfaceorg.opengis.referencing.cs.CSAuthorityFactory
- Overrides:
createCartesianCS
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createSphericalCS
public org.opengis.referencing.cs.SphericalCS createSphericalCS(String code) throws org.opengis.util.FactoryException Creates a 3-dimensional coordinate system with one distance measured from the origin and two angular coordinates. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:cs:
authority:
version:
codehttp://www.opengis.net/def/cs/
authority/
version/
code
- Specified by:
createSphericalCS
in interfaceorg.opengis.referencing.cs.CSAuthorityFactory
- Overrides:
createSphericalCS
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createCylindricalCS
public org.opengis.referencing.cs.CylindricalCS createCylindricalCS(String code) throws org.opengis.util.FactoryException Creates a 3-dimensional coordinate system made of a polar coordinate system extended by a straight perpendicular axis. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:cs:
authority:
version:
codehttp://www.opengis.net/def/cs/
authority/
version/
code
- Specified by:
createCylindricalCS
in interfaceorg.opengis.referencing.cs.CSAuthorityFactory
- Overrides:
createCylindricalCS
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createPolarCS
public org.opengis.referencing.cs.PolarCS createPolarCS(String code) throws org.opengis.util.FactoryException Creates a 2-dimensional coordinate system for coordinates represented by a distance from the origin and an angle from a fixed direction. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:cs:
authority:
version:
codehttp://www.opengis.net/def/cs/
authority/
version/
code
- Specified by:
createPolarCS
in interfaceorg.opengis.referencing.cs.CSAuthorityFactory
- Overrides:
createPolarCS
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the coordinate system for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createCoordinateSystemAxis
public org.opengis.referencing.cs.CoordinateSystemAxis createCoordinateSystemAxis(String code) throws org.opengis.util.FactoryException Creates a coordinate system axis with name, direction, unit and range of values. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:axis:
authority:
version:
codehttp://www.opengis.net/def/axis/
authority/
version/
code
- Specified by:
createCoordinateSystemAxis
in interfaceorg.opengis.referencing.cs.CSAuthorityFactory
- Overrides:
createCoordinateSystemAxis
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the axis for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createUnit
Creates an unit of measurement from a code. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:uom:
authority:
version:
codehttp://www.opengis.net/def/uom/
authority/
version/
code
- Specified by:
createUnit
in interfaceorg.opengis.referencing.cs.CSAuthorityFactory
- Overrides:
createUnit
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the unit of measurement for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createParameterDescriptor
public org.opengis.parameter.ParameterDescriptor<?> createParameterDescriptor(String code) throws org.opengis.util.FactoryException Creates a definition of a single parameter used by an operation method. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:parameter:
authority:
version:
codehttp://www.opengis.net/def/parameter/
authority/
version/
code
- Overrides:
createParameterDescriptor
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the parameter descriptor for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createOperationMethod
public org.opengis.referencing.operation.OperationMethod createOperationMethod(String code) throws org.opengis.util.FactoryException Creates a description of the algorithm and parameters used to perform a coordinate operation. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:method:
authority:
version:
codehttp://www.opengis.net/def/method/
authority/
version/
code
- Specified by:
createOperationMethod
in interfaceorg.opengis.referencing.operation.CoordinateOperationAuthorityFactory
- Overrides:
createOperationMethod
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the operation method for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createCoordinateOperation
public org.opengis.referencing.operation.CoordinateOperation createCoordinateOperation(String code) throws org.opengis.util.FactoryException Creates an operation for transforming coordinates in the source CRS to coordinates in the target CRS. The given code can use any of the following patterns, where version is optional:- authority
:
code - authority
:
version:
code urn:ogc:def:coordinateOperation:
authority:
version:
codehttp://www.opengis.net/def/coordinateOperation/
authority/
version/
code
- Specified by:
createCoordinateOperation
in interfaceorg.opengis.referencing.operation.CoordinateOperationAuthorityFactory
- Overrides:
createCoordinateOperation
in classGeodeticAuthorityFactory
- Parameters:
code
- value allocated by authority.- Returns:
- the operation for the given code.
- Throws:
org.opengis.util.FactoryException
- if the object creation failed.- See Also:
- authority
-
createFromCoordinateReferenceSystemCodes
public Set<org.opengis.referencing.operation.CoordinateOperation> createFromCoordinateReferenceSystemCodes(String sourceCRS, String targetCRS) throws org.opengis.util.FactoryException Creates operations from source and target coordinate reference system codes. If the authority for the two given CRS is handled by the same factory, then this method delegates to that factory. Otherwise this method returns an empty set.- Specified by:
createFromCoordinateReferenceSystemCodes
in interfaceorg.opengis.referencing.operation.CoordinateOperationAuthorityFactory
- Overrides:
createFromCoordinateReferenceSystemCodes
in classGeodeticAuthorityFactory
- Parameters:
sourceCRS
- coded value of source coordinate reference system.targetCRS
- coded value of target coordinate reference system.- Returns:
- the operations from
sourceCRS
totargetCRS
. - Throws:
org.opengis.util.FactoryException
- if the object creation failed.
-
combine
private <T> T combine(Class<T> type, DefinitionURI[] references, boolean isHTTP) throws org.opengis.util.FactoryException Invoked when acreateFoo(…)
method is given a combined URI. A combined URI is a URN or URL referencing other components. For example if the given URI is"urn:ogc:def:crs, crs:EPSG::27700, crs:EPSG::5701"
, then the components are:"urn:ogc:def:crs:EPSG:9.1:27700"
"urn:ogc:def:crs:EPSG:9.1:5701"
- Type Parameters:
T
- compile-time value oftype
argument.- Parameters:
type
- type of object to create.references
- parsed URI of the components.isHTTP
- whether the user URI is an URL (i.e."http://something"
) instead of a URN.- Returns:
- the combined object.
- Throws:
org.opengis.util.FactoryException
- if an error occurred while creating the combined object.
-
remove
private static <T> T remove(DefinitionURI[] references, org.opengis.referencing.IdentifiedObject[] components, Class<T> type) If the giventype
is found in the givenreferences
, sets that reference element tonull
and returns the correspondingcomponents
element. Otherwise returnsnull
. This is equivalent toMap.remove(Object, Object)
wherereferences
are the keys andcomponents
are the values. We do not bother building that map because the arrays are very short (2 or 3 elements). -
combine
private static org.opengis.referencing.crs.GeodeticCRS combine(org.opengis.referencing.datum.GeodeticDatum datum, org.opengis.referencing.cs.CoordinateSystem cs) throws org.opengis.util.FactoryException Invoked when acreateFoo(…)
method is given a combined URI containing a datum and a coordinate system. If the given information are not sufficient or not applicable, then this method returnsnull
.- Parameters:
datum
- the datum, ornull
if missing.cs
- the coordinate system (never null).- Returns:
- the combined CRS, or
null
if the given information are not sufficient. - Throws:
org.opengis.util.FactoryException
- if an error occurred while creating the combined CRS.
-
combine
private static org.opengis.referencing.crs.GeneralDerivedCRS combine(org.opengis.referencing.crs.CoordinateReferenceSystem baseCRS, org.opengis.referencing.operation.Conversion fromBase, org.opengis.referencing.cs.CoordinateSystem cs) throws org.opengis.util.FactoryException Invoked when acreateFoo(…)
method is given a combined URI containing a conversion and a coordinate system. If the given information are not sufficient or not applicable, then this method returnsnull
.- Parameters:
baseCRS
- the CRS on which the derived CRS will be based on, ornull
if missing.fromBase
- the conversion frombaseCRS
to the CRS to be created by this method.cs
- the coordinate system (never null).- Returns:
- the combined CRS, or
null
if the given information are not sufficient. - Throws:
org.opengis.util.FactoryException
- if an error occurred while creating the combined CRS.
-
newIdentifiedObjectFinder
Creates a finder which can be used for looking up unidentified objects. The default implementation delegates the lookups to the underlying factories.- Overrides:
newIdentifiedObjectFinder
in classGeodeticAuthorityFactory
- Returns:
- a finder to use for looking up unidentified objects.
- Throws:
org.opengis.util.FactoryException
- if the finder cannot be created.- See Also:
-
reload
public void reload()Clears the cache and notifies thisMultiAuthoritiesFactory
that all factories will need to be fetched again from the providers given at construction time. In addition, all providers that are instances ofServiceLoader
will have theirreload()
method invoked.This method is intended for use in situations in which new factories can be installed into a running Java virtual machine.
-
applyAndMask
private void applyAndMask(int mask)
-