public class JoltInputEvent
extends java.util.EventObject
Constructor and Description |
---|
JoltInputEvent(java.lang.Object source,
java.lang.String fieldName,
java.lang.Object value)
This constructor is used when the input is a single data
element and it is represented in a native data format.
|
JoltInputEvent(java.lang.Object source,
java.lang.String fieldName,
java.lang.Object[] values)
This constructor is used when the input is a data element with
multiple occurrences and it is represented in a native data format.
|
JoltInputEvent(java.lang.Object source,
java.lang.String fieldName,
java.lang.Object value,
int pos)
This constructor is used when the input is a data element with
multiple occurrences, but only one occurrence is to be set,
and it is represented in a native data format.
|
JoltInputEvent(java.lang.Object source,
java.lang.String fieldName,
java.lang.String textValue)
This constructor is used when the input is a single data
element and it is represented as a String.
|
JoltInputEvent(java.lang.Object source,
java.lang.String fieldName,
java.lang.String[] textValues)
This constructor is used when the input is a data element
with multiple occurrences and it is represented as an array
of Strings.
|
JoltInputEvent(java.lang.Object source,
java.lang.String fieldName,
java.lang.String textValue,
int pos)
This constructor is used when the input is a data element with
multiple occurrences, but only one occurrence is to be set,
and it is represented as a String.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getFieldName()
Get the name of the field.
|
int |
getOccurrenceCount()
Get the number of occurrences of the field.
|
int |
getSingleOccurrence()
Get the position of the field.
|
java.lang.String |
getTextValue()
Get the value as a String
|
java.lang.String[] |
getTextValues()
Get the occurring values as String.
|
java.lang.Object |
getValue()
Get the value in its native representation.
|
java.lang.Object[] |
getValues()
Get the occurring values in its native representation.
|
boolean |
isText()
Returns true if the field value is String, otherwise it returns false.
|
boolean |
isVector()
Returns true if the field has multiple occurrences,
otherwise it returns false.
|
public JoltInputEvent(java.lang.Object source, java.lang.String fieldName, java.lang.Object value)
source
- Event source.fieldName
- Name of the input field (FML name).value
- Value of the field in a native data type,
such as Integer or Float.public JoltInputEvent(java.lang.Object source, java.lang.String fieldName, java.lang.Object value, int pos)
source
- Event source.fieldName
- Name of the input field (FML name).value
- Value of the field in a native data type,
such as Integer or Float.pos
- The position of the data element.public JoltInputEvent(java.lang.Object source, java.lang.String fieldName, java.lang.Object[] values)
source
- Event source.fieldName
- Name of the input field (FML name).values
- Array of occurrences of the field in a native
data type, such as Integer or Float.public JoltInputEvent(java.lang.Object source, java.lang.String fieldName, java.lang.String textValue)
source
- Event source.fieldName
- Name of the input field (FML name).textValue
- Value of the field as a String.public JoltInputEvent(java.lang.Object source, java.lang.String fieldName, java.lang.String textValue, int pos)
source
- Event source.fieldName
- Name of the input field (FML name).textValue
- Value of the field as a String.pos
- The position of the data element.public JoltInputEvent(java.lang.Object source, java.lang.String fieldName, java.lang.String[] textValues)
source
- Event source.fieldName
- Name of the input field (FML name).textValues
- Array of occurrences of the field as String.public java.lang.Object getValue()
public java.lang.Object[] getValues()
public java.lang.String getTextValue()
public java.lang.String[] getTextValues()
public java.lang.String getFieldName()
public int getOccurrenceCount()
public int getSingleOccurrence()
public boolean isText()
public boolean isVector()