Interface Event
- All Superinterfaces:
Comparable<Event>,Element,ModelElement,Property,PropertyElement,SchemaMixedElement,Serializable
- All Known Implementing Classes:
EventImpl
@TypeMetadata(name="Event",
description="This type provides information regarding an event using the Five Ws (checklist) https://en.wikipedia.org/wiki/Five_Ws",
version="1.0.0")
@Change(version="1.0.0",
description="First Version")
public interface Event
extends Property, Comparable<Event>
A property type that describes an event using the "Five Ws" checklist
(What, When, Who, Where, Why) and "How".
This provides a structured way to record information about significant occurrences. For more details, see the Five Ws on Wikipedia.
- Author:
- Luca Frosini (ISTI - CNR)
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe property name for how the event occurred.static final StringThe name of the Event property type.static final StringThe property name for what happened.static final StringThe property name for when the event occurred.static final StringThe property name for where the event occurred.static final StringThe property name for who triggered the event.static final StringThe property name for why the event occurred.Fields inherited from interface org.gcube.informationsystem.base.reference.Element
DATETIME_PATTERN, TYPE_PROPERTYFields inherited from interface org.gcube.informationsystem.model.reference.ModelElement
EXPECTED_TYPE_PROPERTY, SUPERTYPES_PROPERTY -
Method Summary
Modifier and TypeMethodDescriptiongetHow()Returns how the event occurred.getWhat()Returns a description of what happened.getWhen()Returns when the event occurred.getWhere()Returns where the event occurred.getWho()Returns who triggered the event.getWhy()Returns the reason why the event occurred.voidSets how the event occurred.voidSets the description of what happened.voidSets when the event occurred.voidSets where the event occurred.voidSets who triggered the event.voidSets the reason why the event occurred.Methods inherited from interface java.lang.Comparable
compareToMethods inherited from interface org.gcube.informationsystem.base.reference.Element
getTypeNameMethods inherited from interface org.gcube.informationsystem.model.reference.ModelElement
getExpectedtype, getSupertypesMethods inherited from interface org.gcube.informationsystem.model.reference.properties.Property
getAdditionalProperties, getAdditionalProperty, setAdditionalProperties, setAdditionalProperty
-
Field Details
-
NAME
The name of the Event property type.- See Also:
-
WHAT_PROPERTY
The property name for what happened.- See Also:
-
WHEN_PROPERTY
The property name for when the event occurred.- See Also:
-
WHO_PROPERTY
The property name for who triggered the event.- See Also:
-
WHERE_PROPERTY
The property name for where the event occurred.- See Also:
-
WHY_PROPERTY
The property name for why the event occurred.- See Also:
-
HOW_PROPERTY
The property name for how the event occurred.- See Also:
-
-
Method Details
-
getWhat
@ISProperty(name="what", description="WHAT happened.", readonly=true, mandatory=true, nullable=false) String getWhat()Returns a description of what happened.- Returns:
- The event description.
-
setWhat
Sets the description of what happened.- Parameters:
what- The event description.
-
getWhen
@ISProperty(name="when", description="WHEN the event occured. It is represented in the format yyyy-MM-dd HH:mm:ss.SSS Z.", readonly=true, mandatory=true, nullable=false) Date getWhen()Returns when the event occurred.- Returns:
- The date and time of the event.
-
setWhen
Sets when the event occurred.- Parameters:
when- The date and time of the event.
-
getWho
@ISProperty(name="who", description="WHO triggered the event.", readonly=true, mandatory=false, nullable=false) String getWho()Returns who triggered the event.- Returns:
- The identifier of the actor.
-
setWho
Sets who triggered the event.- Parameters:
who- The identifier of the actor.
-
getWhere
@ISProperty(name="where", description="The location (can be virtual) WHERE the event occurred.", readonly=true, mandatory=false, nullable=false) String getWhere()Returns where the event occurred.- Returns:
- The location (physical or virtual).
-
setWhere
Sets where the event occurred.- Parameters:
where- The location.
-
getWhy
@ISProperty(name="why", description="The reason WHY the event occurred.", readonly=true, mandatory=false, nullable=false) String getWhy()Returns the reason why the event occurred.- Returns:
- The reason.
-
setWhy
Sets the reason why the event occurred.- Parameters:
why- The reason.
-
getHow
@ISProperty(name="how", description="How the event occurred.", readonly=true, mandatory=false, nullable=false) String getHow()Returns how the event occurred.- Returns:
- The manner in which the event occurred.
-
setHow
Sets how the event occurred.- Parameters:
how- The manner in which the event occurred.
-