Interface SchemaMixedElement
- All Superinterfaces:
Element,Serializable
- All Known Subinterfaces:
ConsistsOf<S,,T> Context,Encrypted,Event,Facet,IsRelatedTo<S,,T> Metadata,PropagationConstraint,Property,QueryTemplateReference,Relation<S,T>
- All Known Implementing Classes:
ConsistsOfImpl,ContextImpl,DummyFacet,DummyIsRelatedTo,EncryptedImpl,EventImpl,FacetImpl,IsRelatedToImpl,LinkedEntityImpl,MetadataImpl,PropagationConstraintImpl,PropertyElementImpl,PropertyImpl,QueryTemplateReferenceImpl,RelationImpl,TemplateVariableImpl
An element that supports "schema-mixed" mode, allowing for properties not
explicitly defined in the schema.
This interface provides a mechanism to handle additional, non-standard properties as a key-value map. It is useful for elements that need to be extensible and accommodate dynamic attributes.
- Author:
- Luca Frosini (ISTI - CNR)
- See Also:
-
Field Summary
Fields inherited from interface org.gcube.informationsystem.base.reference.Element
DATETIME_PATTERN, NAME, TYPE_PROPERTY -
Method Summary
Modifier and TypeMethodDescriptionReturns a map of all additional properties not defined in the schema.Retrieves a single additional property by its key.voidsetAdditionalProperties(Map<String, Object> additionalProperties) Sets the map of additional properties for the element.voidsetAdditionalProperty(String key, Object value) Sets a single additional property.Methods inherited from interface org.gcube.informationsystem.base.reference.Element
getTypeName
-
Method Details
-
getAdditionalProperties
Returns a map of all additional properties not defined in the schema.- Returns:
- A
Mapcontaining the additional properties, where the key is the property name and the value is the property value.
-
setAdditionalProperties
Sets the map of additional properties for the element.- Parameters:
additionalProperties- AMapof additional properties.
-
getAdditionalProperty
Retrieves a single additional property by its key.- Parameters:
key- The name of the additional property to retrieve.- Returns:
- The value of the property, or
nullif the key is not found.
-
setAdditionalProperty
Sets a single additional property.- Parameters:
key- The name of the additional property.value- The value of the additional property.
-