Class ContextImpl
- java.lang.Object
-
- org.gcube.informationsystem.base.impl.ElementImpl
-
- org.gcube.informationsystem.base.impl.entities.EntityElementImpl
-
- org.gcube.informationsystem.contexts.impl.entities.ContextImpl
-
- All Implemented Interfaces:
Serializable,Element,EntityElement,IdentifiableElement,SchemaMixedElement,Context
public class ContextImpl extends EntityElementImpl implements Context
- Author:
- Luca Frosini (ISTI - CNR)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected Map<String,Object>additionalPropertiesprotected Set<String>allowedAdditionalKeysprotected List<IsParentOf>childrenprotected Stringnameprotected IsParentOfparentprotected Stringstate-
Fields inherited from class org.gcube.informationsystem.base.impl.entities.EntityElementImpl
metadata, uuid
-
Fields inherited from interface org.gcube.informationsystem.contexts.reference.entities.Context
CHILDREN_PROPERTY, NAME, NAME_PROPERTY, PARENT_PROPERTY, STATE
-
Fields inherited from interface org.gcube.informationsystem.base.reference.Element
DATETIME_PATTERN, NAME, TYPE_PROPERTY
-
Fields inherited from interface org.gcube.informationsystem.base.reference.entities.EntityElement
NAME
-
Fields inherited from interface org.gcube.informationsystem.base.reference.IdentifiableElement
ID_PROPERTY, METADATA_PROPERTY
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedContextImpl()ContextImpl(String name)ContextImpl(String name, UUID uuid)ContextImpl(UUID uuid)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddChild(UUID uuid)voidaddChild(Context child)voidaddChild(IsParentOf isParentOf)protected voidaddChildFromJson(IsParentOf isParentOf)Map<String,Object>getAdditionalProperties()ObjectgetAdditionalProperty(String key)List<IsParentOf>getChildren()StringgetName()IsParentOfgetParent()StringgetState()voidsetAdditionalProperties(Map<String,Object> additionalProperties)voidsetAdditionalProperty(String key, Object value)protected voidsetChildrenFromJson(List<IsParentOf> children)voidsetName(String name)voidsetParent(UUID uuid)voidsetParent(Context context)voidsetParent(IsParentOf isParentOf)protected voidsetParentFromJson(IsParentOf isParentOf)voidsetState(String state)-
Methods inherited from class org.gcube.informationsystem.base.impl.entities.EntityElementImpl
getID, getMetadata, setID, setMetadata
-
Methods inherited from class org.gcube.informationsystem.base.impl.ElementImpl
getTypeName, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.gcube.informationsystem.base.reference.Element
getTypeName
-
Methods inherited from interface org.gcube.informationsystem.base.reference.entities.EntityElement
getID, getMetadata, setID, setMetadata
-
-
-
-
Field Detail
-
name
protected String name
-
state
protected String state
-
parent
protected IsParentOf parent
-
children
protected List<IsParentOf> children
-
-
Method Detail
-
getParent
public IsParentOf getParent()
-
setParentFromJson
protected void setParentFromJson(IsParentOf isParentOf) throws org.gcube.com.fasterxml.jackson.core.JsonProcessingException
- Throws:
org.gcube.com.fasterxml.jackson.core.JsonProcessingException
-
setParent
public void setParent(IsParentOf isParentOf)
-
getChildren
public List<IsParentOf> getChildren()
- Specified by:
getChildrenin interfaceContext
-
setChildrenFromJson
protected void setChildrenFromJson(List<IsParentOf> children) throws org.gcube.com.fasterxml.jackson.core.JsonProcessingException
- Throws:
org.gcube.com.fasterxml.jackson.core.JsonProcessingException
-
addChildFromJson
protected void addChildFromJson(IsParentOf isParentOf) throws org.gcube.com.fasterxml.jackson.core.JsonProcessingException
- Throws:
org.gcube.com.fasterxml.jackson.core.JsonProcessingException
-
addChild
public void addChild(IsParentOf isParentOf)
-
getAdditionalProperties
public Map<String,Object> getAdditionalProperties()
- Specified by:
getAdditionalPropertiesin interfaceContext- Specified by:
getAdditionalPropertiesin interfaceSchemaMixedElement
-
setAdditionalProperties
public void setAdditionalProperties(Map<String,Object> additionalProperties)
- Specified by:
setAdditionalPropertiesin interfaceContext- Specified by:
setAdditionalPropertiesin interfaceSchemaMixedElement
-
getAdditionalProperty
public Object getAdditionalProperty(String key)
- Specified by:
getAdditionalPropertyin interfaceContext- Specified by:
getAdditionalPropertyin interfaceSchemaMixedElement
-
setAdditionalProperty
public void setAdditionalProperty(String key, Object value)
- Specified by:
setAdditionalPropertyin interfaceContext- Specified by:
setAdditionalPropertyin interfaceSchemaMixedElement
-
-