Package edu.fiu.jtlex.timeml.data
Interface ITimeMLTimex
- All Superinterfaces:
ITimeMLNode
- All Known Implementing Classes:
TimeMLTimex
Represents the TIME tag.
This assumes usage of TimeML TIMEX3 standards;
"Since the details of the tag set that TimeML uses to annotate temporal
expressions differ in detail both from the TIMEX tag in STAG (Sheffield
Temporal Annotation Guidelines) and the TIMEX2 tag in TIDES,
we here use the tag name TIMEX3 for temporal expressions."
-TimeML Annotation
Guidelines Version 1.2.1
- Since:
- jTLEX 1.0
- Author:
- ceber003
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic enum
An enum that represents the seven different functions an object may belong to.
Function may belong to: CREATION_TIMEMODIFICATION_TIME PUBLICATION_TIMERELEASE_TIMERECEPTION_TIME EXPIRATION_TIMENONEstatic enum
An enum that represents the twelve different Mod states an object may belong to.static enum
An enum that represents the four different types an object may belong to.
Timex may belong to: DATETIME DURATIONSET typeNested classes/interfaces inherited from interface edu.fiu.jtlex.timeml.graph.ITimeMLNode
ITimeMLNode.IType
-
Method Summary
Modifier and TypeMethodDescriptionclone()
Creates and returns a field-by-field copy of the Timex.boolean
Checks if this Timex equals an object.int
Returns the integer part of the anchortimeId.Returns the string part of the anchortimeId.int
Returns the integer part of the beginpointId.Returns the string part of the beginpointId.int
Returns the integer part of the endpointId.Returns the string part of the endpointId.getFreq()
Returns frequency String portion.Returns the function to which the object belongs.int
getId()
Returns the integer part of the tID.getIdStr()
Returns the tID.getMod()
Returns the mod to which the object belongs.Returns the phrase from the text annotated as timex.getQuant()
Returns the quantity to which the object belongs.boolean
Returns the inary attribute which expresses that the value of the temporal expression needs to be determined via evaluation of a temporal function.getType()
Returns the type of the timex.getValue()
Returns the string representation of the value.toJson()
Returns the JSON (RFC 8259) representation of the Timex.toString()
Returns the info of the Timex in String format.
-
Method Details
-
getId
int getId()Returns the integer part of the tID. Will never be null as it is required for the constructor.- Specified by:
getId
in interfaceITimeMLNode
- Returns:
- the tID of the timex.
- Since:
- jTLEX 1.0
-
getIdStr
String getIdStr()Returns the tID. Will never be null since the tID was required in the constructor.- Specified by:
getIdStr
in interfaceITimeMLNode
- Returns:
- the String representation of the ID.
- Since:
- jTLEX 1.0
-
getType
ITimeMLTimex.TimexType getType()Returns the type of the timex.- Specified by:
getType
in interfaceITimeMLNode
- Returns:
- the type of the timex.
- Since:
- jTLEX 1.0
-
getValue
String getValue()Returns the string representation of the value. The value of the the timex tag determines what the actual amount of time for the date, time, duration, and set types.- Returns:
- the string representation of the value. May not be null.
- Since:
- jTLEX 1.0
-
getMod
ITimeMLTimex.TimexMod getMod()Returns the mod to which the object belongs. This value is optional.- Returns:
- the mod to which the object belongs.
May be
null
. - Since:
- jTLEX 1.0
- See Also:
-
getTemporalFunction
boolean getTemporalFunction()Returns the inary attribute which expresses that the value of the temporal expression needs to be determined via evaluation of a temporal function.- Returns:
- the inary attribute which expresses that the value of the temporal expression needs to be determined via evaluation of a temporal function.
- Since:
- jTLEX 1.0
-
getAnchorTimeId
int getAnchorTimeId()Returns the integer part of the anchortimeId. Each anchortime has to be identified by a unique ID number. This value is optional.- Returns:
- the integer part of the anchortimeId. May not be negative
- Since:
- jTLEX 1.0
-
getAnchorTimeIdStr
String getAnchorTimeIdStr()Returns the string part of the anchortimeId. Each anchortime has to be identified by a unique ID number. This value is optional.- Returns:
- the string part of the anchortimeId. May not be null.
- Since:
- jTLEX 1.0
-
getFunction
ITimeMLTimex.FunctionInDocument getFunction()Returns the function to which the object belongs. Function in document can be one of seven values. If it is not specified then it will be set as 'NONE' by default.- Returns:
- the function to which the object belongs.
May be
null
. - Since:
- jTLEX 1.0
-
getBeginPoint
int getBeginPoint()Returns the integer part of the beginpointId. Beginpoint is only used if the expression is anchored to another timex expression. Each beginpoint has to be identified by a unique ID number. If only endpoint is provided may create an empty timex to fill in.- Returns:
- the integer part of the beginpointId. May not be negative
- Since:
- jTLEX 1.0
-
getBeginPointStr
String getBeginPointStr()Returns the string part of the beginpointId. Beginpoint is only used if the expression is anchored to another timex expression. Each beginpoint has to be identified by a unique ID number. If only endpoint is provided may create an empty timex to fill in.- Returns:
- the string part of the beginpointId.
May not be
null
. - Since:
- jTLEX 1.0
-
getEndPoint
int getEndPoint()Returns the integer part of the endpointId. Endpoint is only used if the expression is anchored to another timex expression. Each endpoint has to be identified by a unique ID number. If only beginpoint is provided may create an empty timex to fill in.- Returns:
- the integer part of the endpointId. May not be negative.
- Since:
- jTLEX 1.0
-
getEndPointStr
String getEndPointStr()Returns the string part of the endpointId. Endpoint is only used if the expression is anchored to another timex expression. Each endpoint has to be identified by a unique ID number. If only beginpoint is provided may create an empty timex to fill in.- Returns:
- the string part of the endpointId.
May not be
null
. - Since:
- jTLEX 1.0
-
getQuant
String getQuant()Returns the quantity to which the object belongs. The quant value is only used if the timex type is 'SET'.- Returns:
- the quantity to which the object belongs.
May be
null
. - Since:
- jTLEX 1.0
-
getFreq
String getFreq()Returns frequency String portion. The frequency value is only used if the timex type is 'SET'. The integer value determines the number of time the frequency takes. i.e: 2 Weeks, 3 Months, 1 Day, etc.- Returns:
- frequency String portion.
May be
null
. - Since:
- jTLEX 1.0
-
getPhrase
String getPhrase()Returns the phrase from the text annotated as timex.- Returns:
- the phrase from the text annotated as timex.
- Since:
- jTLEX 1.0
May be
null
.
-
toString
String toString()Returns the info of the Timex in String format. -
toJson
String toJson()Returns the JSON (RFC 8259) representation of the Timex. Will never return null.- Specified by:
toJson
in interfaceITimeMLNode
- Returns:
- the JSON format of the Timex.
- Since:
- jTLEX 1.0
-
clone
TimeMLTimex clone()Creates and returns a field-by-field copy of the Timex. Will never return null.- Specified by:
clone
in interfaceITimeMLNode
- Returns:
- a field-by-field copy of the Timex.
- Since:
- jTLEX 1.0
-
equals
Checks if this Timex equals an object.- Specified by:
equals
in interfaceITimeMLNode
- Overrides:
equals
in classObject
- Parameters:
o
- The object to compare against.- Returns:
- True if both events are equal, i.e. same ID and type, or else false.
- Throws:
NullPointerException
- If the object to compare against is false.- Since:
- jTLEX 1.0
-