Class EmbeddedResources
java.lang.Object
org.apache.sis.setup.InstallationResources
org.apache.sis.resources.embedded.EmbeddedResources
public class EmbeddedResources
extends org.apache.sis.setup.InstallationResources
Provides an embedded database for the EPSG geodetic dataset and other resources.
Provides also a copy of the EPSG terms of use,
which should be accepted by users before the EPSG dataset can be installed.
- Since:
- 0.8
- Version:
- 1.4
- Author:
- Martin Desruisseaux (Geomatys)
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionCreates a new provider for connections to the embedded database. -
Method Summary
Modifier and TypeMethodDescriptionReturns the pseudo-authority, which is"Embedded".getLicense(String authority, Locale locale, String mimeType) Returns the license of embedded data.getResource(String authority, int index) Returns the data source for embedded database.String[]getResourceNames(String authority) Returns the data source name, which is"SpatialMetadata".openScript(String authority, int resource) Unconditionally throws an exception since the embedded database is not provided as SQL scripts.Methods inherited from class org.apache.sis.setup.InstallationResources
getInstructionURL, load
-
Constructor Details
-
EmbeddedResources
public EmbeddedResources()Creates a new provider for connections to the embedded database.
-
-
Method Details
-
getAuthorities
Returns the pseudo-authority, which is"Embedded".- Specified by:
getAuthoritiesin classorg.apache.sis.setup.InstallationResources- Returns:
"Embedded"pseudo-authority.
-
getLicense
Returns the license of embedded data.- Specified by:
getLicensein classorg.apache.sis.setup.InstallationResources- Parameters:
authority- shall be"Embedded".locale- the preferred locale for the terms of use.mimeType- either"text/plain"or"text/html".- Returns:
- the terms of use in plain text or HTML, or
nullif none. - Throws:
IllegalArgumentException- if the givenauthorityargument is not the expected values.IOException- if an error occurred while reading the license file.
-
getResourceNames
Returns the data source name, which is"SpatialMetadata".- Specified by:
getResourceNamesin classorg.apache.sis.setup.InstallationResources- Parameters:
authority- shall be"Embedded".- Returns:
"SpatialMetadata".
-
getResource
Returns the data source for embedded database.- Overrides:
getResourcein classorg.apache.sis.setup.InstallationResources- Parameters:
authority- shall be"Embedded".index- shall be 0.- Returns:
- the embedded data source.
-
openScript
Unconditionally throws an exception since the embedded database is not provided as SQL scripts.- Specified by:
openScriptin classorg.apache.sis.setup.InstallationResources- Parameters:
authority- shall be"Embedded".resource- shall be 0.- Returns:
- never return.
- Throws:
IOException- always thrown.
-