Module org.apache.sis.metadata
Class DefaultCoupledResource
Object
AbstractMetadata
ModifiableMetadata
ISOMetadata
DefaultCoupledResource
- All Implemented Interfaces:
Serializable
,Emptiable
,LenientComparable
,IdentifiedObject
@UML(identifier="SV_CoupledResource",
specification=ISO_19115)
public class DefaultCoupledResource
extends ISOMetadata
Links a given operation name with a resource identified by an "identifier".
Note on International Standard versions
This class is derived from a new type defined in the ISO 19115 international standard published in 2014, while GeoAPI 3.0 is based on the version published in 2003. Consequently this implementation class does not yet implement a GeoAPI interface, but is expected to do so after the next GeoAPI releases. When the interface will become available, all references to this implementation class in Apache SIS will be replaced be references to the
This class is derived from a new type defined in the ISO 19115 international standard published in 2014, while GeoAPI 3.0 is based on the version published in 2003. Consequently this implementation class does not yet implement a GeoAPI interface, but is expected to do so after the next GeoAPI releases. When the interface will become available, all references to this implementation class in Apache SIS will be replaced be references to the
CoupledResource
interface.
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.5
- 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 coupled resource.Constructs a new instance initialized with the values from the specified metadata object.DefaultCoupledResource
(ScopedName name, Citation reference, DataIdentification resource, DefaultOperationMetadata operation) Constructs a new coupled resource initialized to the specified values. -
Method Summary
Modifier and TypeMethodDescriptionReturns the service operation.Returns references to the resource on which the services operates.Returns the tightly coupled resources.Returns scoped identifier of the resource in the context of the given service instance.void
setOperation
(DefaultOperationMetadata newValue) Sets a new service operation.void
setResourceReferences
(Collection<? extends Citation> newValues) Sets references to the resource on which the services operates.void
setResources
(Collection<? extends DataIdentification> newValues) Sets the tightly coupled resources.void
setScopedName
(ScopedName newValue) Sets the identifier of the resource in the context of the given service instance.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
-
Constructor Details
-
DefaultCoupledResource
public DefaultCoupledResource()Constructs an initially empty coupled resource. -
DefaultCoupledResource
public DefaultCoupledResource(ScopedName name, Citation reference, DataIdentification resource, DefaultOperationMetadata operation) Constructs a new coupled resource initialized to the specified values.- Parameters:
name
- scoped identifier of the resource in the context of the given service instance.reference
- reference to the reference to the resource on which the services operates.resource
- the tightly coupled resource.operation
- the service operation.
-
DefaultCoupledResource
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.
-
-
Method Details
-
getScopedName
@UML(identifier="scopedName", obligation=OPTIONAL, specification=ISO_19115) public ScopedName getScopedName()Returns scoped identifier of the resource in the context of the given service instance.- Returns:
- identifier of the resource, or
null
if none.
-
setScopedName
Sets the identifier of the resource in the context of the given service instance.- Parameters:
newValue
- the new identifier of the resource.
-
getResourceReferences
@UML(identifier="resourceReference", obligation=OPTIONAL, specification=ISO_19115) public Collection<Citation> getResourceReferences()Returns references to the resource on which the services operates.- Returns:
- references to the resource on which the services operates.
-
setResourceReferences
Sets references to the resource on which the services operates.- Parameters:
newValues
- the new references to the resource on which the services operates.
-
getResources
@UML(identifier="resource", obligation=OPTIONAL, specification=ISO_19115) public Collection<DataIdentification> getResources()Returns the tightly coupled resources.- Returns:
- tightly coupled resources.
-
setResources
Sets the tightly coupled resources.- Parameters:
newValues
- the new tightly coupled resources.
-
getOperation
@UML(identifier="operation", obligation=OPTIONAL, specification=ISO_19115) public DefaultOperationMetadata getOperation()Returns the service operation.Upcoming API change — generalization
The return type will be changed to theOperationMetadata
interface when GeoAPI will provide it (tentatively in GeoAPI 3.1).- Returns:
- the service operation, or
null
if none.
-
setOperation
Sets a new service operation.Upcoming API change — generalization
The argument type will be changed to theOperationMetadata
interface when GeoAPI will provide it (tentatively in GeoAPI 3.1).- Parameters:
newValue
- the new service operation.
-