Interface LinkedEntity
-
- All Superinterfaces:
Comparable<LinkedEntity>,Element,PropertyElement,Serializable
- All Known Implementing Classes:
LinkedEntityImpl
@TypeMetadata(name="LinkedEntity", description=" A convenient type to define a Resource in terms of: mandatory/recommended ConsistsOf->Facets; suggested IsRelatedTo->Resource.", version="1.0.0") @Change(version="1.0.0", description="First Version") public interface LinkedEntity extends PropertyElement, Comparable<LinkedEntity>
A property type for defining relationships between entities, including cardinality constraints.This is used to specify:
- Mandatory or recommended
ConsistsOfrelationships to facets. - Suggested
IsRelatedTorelationships to other resources.
- Author:
- Luca Frosini (ISTI - CNR)
-
-
Field Summary
Fields Modifier and Type Field Description static StringDESCRIPTION_PROPERTYThe property name for the description of the link.static StringMAX_PROPERTYThe property name for the maximum cardinality.static StringMIN_PROPERTYThe property name for the minimum cardinality.static StringNAMEThe name of the LinkedEntity property type.static StringRELATION_PROPERTYThe property name for the relation of the link.static StringSOURCE_PROPERTYThe property name for the source of the link.static StringTARGET_PROPERTYThe property name for the target of the link.-
Fields inherited from interface org.gcube.informationsystem.base.reference.Element
DATETIME_PATTERN, TYPE_PROPERTY
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description StringgetDescription()Returns the description of the link.IntegergetMax()Returns the maximum cardinality of the link.IntegergetMin()Returns the minimum cardinality of the link.StringgetRelation()Returns the name of the relation type.StringgetSource()Returns the name of the source entity type.StringgetTarget()Returns the name of the target entity type.voidsetDescription(String description)Sets the description of the link.voidsetMax(Integer max)Sets the maximum cardinality of the link.voidsetMin(Integer min)Sets the minimum cardinality of the link.voidsetRelation(String relation)Sets the name of the relation type.voidsetSource(String source)Sets the name of the source entity type.voidsetTarget(String target)Sets the name of the target entity type.-
Methods inherited from interface java.lang.Comparable
compareTo
-
Methods inherited from interface org.gcube.informationsystem.base.reference.Element
getTypeName
-
-
-
-
Field Detail
-
NAME
static final String NAME
The name of the LinkedEntity property type.- See Also:
- Constant Field Values
-
SOURCE_PROPERTY
static final String SOURCE_PROPERTY
The property name for the source of the link.- See Also:
- Constant Field Values
-
RELATION_PROPERTY
static final String RELATION_PROPERTY
The property name for the relation of the link.- See Also:
- Constant Field Values
-
TARGET_PROPERTY
static final String TARGET_PROPERTY
The property name for the target of the link.- See Also:
- Constant Field Values
-
DESCRIPTION_PROPERTY
static final String DESCRIPTION_PROPERTY
The property name for the description of the link.- See Also:
- Constant Field Values
-
MIN_PROPERTY
static final String MIN_PROPERTY
The property name for the minimum cardinality.- See Also:
- Constant Field Values
-
MAX_PROPERTY
static final String MAX_PROPERTY
The property name for the maximum cardinality.- See Also:
- Constant Field Values
-
-
Method Detail
-
getSource
@ISProperty(name="source", readonly=true, mandatory=true, nullable=false) String getSource()
Returns the name of the source entity type.- Returns:
- The source type name.
-
setSource
void setSource(String source)
Sets the name of the source entity type.- Parameters:
source- The source type name.
-
getRelation
@ISProperty(name="relation", readonly=true, mandatory=true, nullable=false) String getRelation()
Returns the name of the relation type.- Returns:
- The relation type name.
-
setRelation
void setRelation(String relation)
Sets the name of the relation type.- Parameters:
relation- The relation type name.
-
getTarget
@ISProperty(name="target", readonly=true, mandatory=true, nullable=false) String getTarget()
Returns the name of the target entity type.- Returns:
- The target type name.
-
setTarget
void setTarget(String target)
Sets the name of the target entity type.- Parameters:
target- The target type name.
-
getDescription
@ISProperty(name="description", readonly=true, mandatory=true, nullable=false) String getDescription()
Returns the description of the link.- Returns:
- The description.
-
setDescription
void setDescription(String description)
Sets the description of the link.- Parameters:
description- The description.
-
getMin
@ISProperty(name="min", readonly=true, mandatory=true, nullable=false) Integer getMin()
Returns the minimum cardinality of the link.- Returns:
- The minimum cardinality.
-
setMin
void setMin(Integer min)
Sets the minimum cardinality of the link.- Parameters:
min- The minimum cardinality.
-
getMax
@ISProperty(name="max", readonly=true, mandatory=true, nullable=true) Integer getMax()
Returns the maximum cardinality of the link.- Returns:
- The maximum cardinality.
-
setMax
void setMax(Integer max)
Sets the maximum cardinality of the link.- Parameters:
max- The maximum cardinality.
-
-