Module org.apache.sis.metadata
Class DefaultDataIdentification
Object
AbstractMetadata
ModifiableMetadata
ISOMetadata
AbstractIdentification
DefaultDataIdentification
- All Implemented Interfaces:
Serializable
,Emptiable
,LenientComparable
,IdentifiedObject
,DataIdentification
,Identification
Information required to identify a dataset.
The following properties are mandatory or conditional (i.e. mandatory under some circumstances)
in a well-formed metadata according ISO 19115:
MD_DataIdentification
├─citation………………………………………
Citation data for the resource(s).
│ ├─title……………………………………
Name by which the cited resource is known.
│ └─date………………………………………
Reference date for the cited resource.
├─abstract………………………………………
Brief narrative summary of the content of the resource(s).
├─language………………………………………
Language(s) used within the dataset.
├─characterSet……………………………
Full name of the character coding standard(s) used for the dataset.
├─topicCategory…………………………
Main theme(s) of the dataset.
└─extent……………………………………………
Bounding polygon, vertical, and temporal extent of the dataset.
├─description……………………
The spatial and temporal extent for the referring object.
├─geographicElement……
Geographic component of the extent of the referring object.
├─temporalElement…………
Temporal component of the extent of the referring object.
└─verticalElement…………
Vertical component of the extent of the referring object.Limitations
- Instances of this class are not synchronized for multi-threading. Synchronization, if needed, is caller's responsibility.
- Serialized objects of this class are not guaranteed to be compatible with future Apache SIS releases.
Serialization support is appropriate for short term storage or RMI between applications running the
same version of Apache SIS. For long term storage, use
XML
instead.
- Since:
- 0.3
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class ModifiableMetadata
ModifiableMetadata.State
-
Field Summary
Fields inherited from class ISOMetadata
identifiers
-
Constructor Summary
ConstructorDescriptionConstructs an initially empty data identification.DefaultDataIdentification
(Citation citation, CharSequence abstracts, Locale language, TopicCategory topicCategory) Creates a data identification initialized to the specified values.Constructs a new instance initialized with the values from the specified metadata object. -
Method Summary
Modifier and TypeMethodDescriptionstatic DefaultDataIdentification
castOrCopy
(DataIdentification object) Returns a SIS metadata implementation with the values of the given arbitrary implementation.Deprecated.Returns a description of the resource in the producer's processing environment.Deprecated.Replaced bygetLocalesAndCharsets().keySet()
.Returns the language(s) and character set(s) used within the dataset.Any other descriptive information about the resource.void
setCharacterSets
(Collection<? extends CharacterSet> newValues) Deprecated.Replaced by putting values ingetLocalesAndCharsets()
map.void
setEnvironmentDescription
(InternationalString newValue) Sets the description of the resource in the producer's processing environment.void
setLanguages
(Collection<? extends Locale> newValues) Deprecated.Replaced by putting keys ingetLocalesAndCharsets()
map.void
setLocalesAndCharsets
(Map<? extends Locale, ? extends Charset> newValues) Sets the language(s) and character set(s) used within the dataset.void
setSupplementalInformation
(InternationalString newValue) Sets any other descriptive information about the resource.Methods inherited from class AbstractIdentification
castOrCopy, getAbstract, getAdditionalDocumentations, getAggregationInfo, getAssociatedResources, getCitation, getCredits, getDescriptiveKeywords, getExtents, getGraphicOverviews, getPointOfContacts, getProcessingLevel, getPurpose, getResourceConstraints, getResourceFormats, getResourceMaintenances, getResourceSpecificUsages, getSpatialRepresentationTypes, getSpatialResolutions, getStatus, getTopicCategories, setAbstract, setAdditionalDocumentations, setAggregationInfo, setAssociatedResources, setCitation, setCredits, setDescriptiveKeywords, setExtents, setGraphicOverviews, setPointOfContacts, setProcessingLevel, setPurpose, setResourceConstraints, setResourceFormats, setResourceMaintenances, setResourceSpecificUsages, setSpatialRepresentationTypes, setSpatialResolutions, setStatus, setTopicCategories
Methods inherited from class ISOMetadata
getIdentifier, getIdentifierMap, getIdentifiers, getStandard, setIdentifier, transitionTo
Methods inherited from class ModifiableMetadata
checkWritePermission, collectionType, copyCollection, copyList, copyMap, copySet, deepCopy, nonNullCollection, nonNullList, nonNullMap, nonNullSet, singleton, state, writeCollection, writeList, writeMap, writeSet
Methods inherited from class AbstractMetadata
asMap, asTreeTable, equals, equals, getInterface, hashCode, isEmpty, prune, toString
Methods inherited from class Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface DataIdentification
getExtents, getSpatialRepresentationTypes, getSpatialResolutions, getTopicCategories
Methods inherited from interface Identification
getAbstract, getAggregationInfo, getCitation, getCredits, getDescriptiveKeywords, getGraphicOverviews, getPointOfContacts, getPurpose, getResourceConstraints, getResourceFormats, getResourceMaintenances, getResourceSpecificUsages, getStatus
-
Constructor Details
-
DefaultDataIdentification
public DefaultDataIdentification()Constructs an initially empty data identification. -
DefaultDataIdentification
public DefaultDataIdentification(Citation citation, CharSequence abstracts, Locale language, TopicCategory topicCategory) Creates a data identification initialized to the specified values.- Parameters:
citation
- the citation data for the resource(s), ornull
if none.abstracts
- a brief narrative summary of the content of the resource(s), ornull
if none.language
- the language used within the dataset, ornull
if none.topicCategory
- the main theme of the dataset, ornull
if none.
-
DefaultDataIdentification
Constructs a new instance initialized with the values from the specified metadata object. This is a shallow copy constructor, because the other metadata contained in the given object are not recursively copied.- Parameters:
object
- the metadata to copy values from, ornull
if none.- See Also:
-
-
Method Details
-
castOrCopy
Returns a SIS metadata implementation with the values of the given arbitrary implementation. This method performs the first applicable action in the following choices:- If the given object is
null
, then this method returnsnull
. - Otherwise if the given object is already an instance of
DefaultDataIdentification
, then it is returned unchanged. - Otherwise a new
DefaultDataIdentification
instance is created using the copy constructor and returned. Note that this is a shallow copy operation, because the other metadata contained in the given object are not recursively copied.
- Parameters:
object
- the object to get as a SIS implementation, ornull
if none.- Returns:
- a SIS implementation containing the values of the given object (may be the
given object itself), or
null
if the argument was null.
- If the given object is
-
getLocalesAndCharsets
@UML(identifier="defaultLocale+otherLocale", obligation=CONDITIONAL, specification=ISO_19115) public Map<Locale,Charset> getLocalesAndCharsets()Returns the language(s) and character set(s) used within the dataset. The first element in iteration order is the default language. All other elements, if any, are alternate language(s) used within the resource.- Returns:
- language(s) and character set(s) used within the dataset.
- Since:
- 1.0
-
setLocalesAndCharsets
Sets the language(s) and character set(s) used within the dataset. The first element in iteration order should be the default language. All other elements, if any, are alternate language(s) used within the resource.- Parameters:
newValues
- the new language(s) and character set(s) used within the dataset.- Since:
- 1.0
-
getLanguages
Deprecated.Replaced bygetLocalesAndCharsets().keySet()
.Returns the language(s) used within the resource. The first element in iteration order shall be the default language. All other elements, if any, are alternate language(s) used within the resource.The language string representations should use ISO 639-2 language code as returned by
Locale.getISO3Language()
.- Specified by:
getLanguages
in interfaceDataIdentification
- Returns:
- language(s) used.
-
setLanguages
Deprecated.Replaced by putting keys ingetLocalesAndCharsets()
map.Sets the language(s) used within the resource.- Parameters:
newValues
- the new languages.
-
getCharacterSets
Deprecated.Replaced bygetLocalesAndCharsets().values()
.Returns the character coding standard used for the dataset.Upcoming API change — JDK integration
The element type may change to theCharset
class in GeoAPI 4.0.- Specified by:
getCharacterSets
in interfaceDataIdentification
- Returns:
- character coding standard(s) used.
-
setCharacterSets
Deprecated.Replaced by putting values ingetLocalesAndCharsets()
map.Sets the character coding standard used for the dataset.Upcoming API change — JDK integration
The element type may change to theCharset
class in GeoAPI 4.0.- Parameters:
newValues
- the new character sets.
-
getEnvironmentDescription
Returns a description of the resource in the producer's processing environment. This includes items such as the software, the computer operating system, file name, and the dataset size.- Specified by:
getEnvironmentDescription
in interfaceDataIdentification
- Returns:
- description of the resource in the producer's processing environment, or
null
.
-
setEnvironmentDescription
Sets the description of the resource in the producer's processing environment.- Parameters:
newValue
- the new environment description.
-
getSupplementalInformation
Any other descriptive information about the resource.- Specified by:
getSupplementalInformation
in interfaceDataIdentification
- Returns:
- other descriptive information, or
null
.
-
setSupplementalInformation
Sets any other descriptive information about the resource.- Parameters:
newValue
- the new supplemental information.
-
getLocalesAndCharsets().values()
.