/** * Returns the first implementation of {@link DatumAuthorityFactory} matching the specified * hints. If no implementation matches, a new one is created if possible or an exception is * thrown otherwise. If more than one implementation is registered and an {@linkplain * #setVendorOrdering ordering is set}, then the preferred implementation is returned. Otherwise * an arbitrary one is selected. * * @param authority The desired authority (e.g. "EPSG"). * @param hints An optional map of hints, or {@code null} if none. * @return The first datum authority factory that matches the supplied hints. * @throws FactoryRegistryException if no implementation was found or can be created for the * {@link DatumAuthorityFactory} interface. */ public static DatumAuthorityFactory getDatumAuthorityFactory( final String authority, final Hints hints) throws FactoryRegistryException { return getAuthorityFactory( DatumAuthorityFactory.class, authority, hints, Hints.DATUM_AUTHORITY_FACTORY); }
/** * Returns the first implementation of {@link CoordinateOperationAuthorityFactory} matching the * specified hints. If no implementation matches, a new one is created if possible or an * exception is thrown otherwise. If more than one implementation is registered and an * {@linkplain #setVendorOrdering ordering is set}, then the preferred implementation is * returned. Otherwise an arbitrary one is selected. * * @param authority The desired authority (e.g. "EPSG"). * @param hints An optional map of hints, or {@code null} if none. * @return The first coordinate operation authority factory that matches the supplied hints. * @throws FactoryRegistryException if no implementation was found or can be created for the * {@link CoordinateOperationAuthorityFactory} interface. */ public static CoordinateOperationAuthorityFactory getCoordinateOperationAuthorityFactory( final String authority, final Hints hints) throws FactoryRegistryException { return getAuthorityFactory( CoordinateOperationAuthorityFactory.class, authority, hints, Hints.COORDINATE_OPERATION_AUTHORITY_FACTORY); }
/** * Returns the first implementation of {@link CSAuthorityFactory} matching the specified hints. * If no implementation matches, a new one is created if possible or an exception is thrown * otherwise. If more than one implementation is registered and an {@linkplain * #setVendorOrdering ordering is set}, then the preferred implementation is returned. Otherwise * an arbitrary one is selected. * * <p>Hints that may be understood includes {@link Hints#FORCE_LONGITUDE_FIRST_AXIS_ORDER * FORCE_LONGITUDE_FIRST_AXIS_ORDER}, {@link Hints#FORCE_STANDARD_AXIS_UNITS * FORCE_STANDARD_AXIS_UNITS} and {@link Hints#FORCE_STANDARD_AXIS_DIRECTIONS * FORCE_STANDARD_AXIS_DIRECTIONS} and {@link Hints#VERSION VERSION}. * * @param authority The desired authority (e.g. "EPSG"). * @param hints An optional map of hints, or {@code null} if none. * @return The first coordinate system authority factory that matches the supplied hints. * @throws FactoryRegistryException if no implementation was found or can be created for the * {@link CSAuthorityFactory} interface. */ public static CSAuthorityFactory getCSAuthorityFactory( final String authority, final Hints hints) throws FactoryRegistryException { return getAuthorityFactory( CSAuthorityFactory.class, authority, hints, Hints.CS_AUTHORITY_FACTORY); }
return getAuthorityFactory( CRSAuthorityFactory.class, authority, hints, Hints.CRS_AUTHORITY_FACTORY);