Package ag.smaser.trip.cfw
Class ImportValue
- java.lang.Object
-
- ag.smaser.trip.cfw.ImportValue
-
public class ImportValue extends java.lang.Object
Represents a value imported by an import connector.
-
-
Constructor Summary
Constructors Constructor Description ImportValue(java.lang.String id)
Creates a new value object for an import item.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Object
getData()
Returns the data value as an object, or null if no value has been assigned.java.lang.String
getId()
Returns the id or tag of the value.java.util.Map<java.lang.String,java.lang.String>
getProperties()
Get dictionary with value properties.boolean
isBinary()
Returns true if the data of this item is a byte array (byte[]).boolean
isDate()
Returns true if the data of this item is a Date objectboolean
isDouble()
Returns true if the data of this item is fouble floating point value (double)boolean
isInteger()
Returns true if the data of this item is an integer (int)boolean
isNull()
Returns true if this item has no data.boolean
isString()
Returns true if the data of this item is a String objectvoid
setData(byte[] data)
Assigns a byte array as the data value for this itemvoid
setData(double data)
Assigns a double as the data value for this itemvoid
setData(int data)
Assigns an int as the data value for this itemvoid
setData(java.lang.String data)
Assigns a string as the data value for this itemvoid
setData(java.util.Date data)
Assigns a Date object as the data value for this itemvoid
setProperty(java.lang.String key, java.lang.String value)
Set a property for this import value.
-
-
-
Method Detail
-
getId
public java.lang.String getId()
Returns the id or tag of the value.- Returns:
- Value id
-
getData
public java.lang.Object getData()
Returns the data value as an object, or null if no value has been assigned.- Returns:
- The value as an Object
-
setData
public void setData(java.lang.String data)
Assigns a string as the data value for this item- Parameters:
data
- Value
-
setData
public void setData(byte[] data)
Assigns a byte array as the data value for this item- Parameters:
data
- Value
-
setData
public void setData(int data)
Assigns an int as the data value for this item- Parameters:
data
- Value
-
setData
public void setData(double data)
Assigns a double as the data value for this item- Parameters:
data
- Value
-
setData
public void setData(java.util.Date data)
Assigns a Date object as the data value for this item- Parameters:
data
- Value
-
isNull
public boolean isNull()
Returns true if this item has no data.- Returns:
- True if the value is null
-
isString
public boolean isString()
Returns true if the data of this item is a String object- Returns:
- True if the value is a string
-
isBinary
public boolean isBinary()
Returns true if the data of this item is a byte array (byte[]).- Returns:
- True if the value is a byte array
-
isInteger
public boolean isInteger()
Returns true if the data of this item is an integer (int)- Returns:
- True if the value is an integers
-
isDouble
public boolean isDouble()
Returns true if the data of this item is fouble floating point value (double)- Returns:
- True if the value is a double
-
isDate
public boolean isDate()
Returns true if the data of this item is a Date object- Returns:
- True if the value is a date
-
getProperties
public java.util.Map<java.lang.String,java.lang.String> getProperties()
Get dictionary with value properties.- Returns:
- Property dictionary
-
setProperty
public void setProperty(java.lang.String key, java.lang.String value)
Set a property for this import value.- Parameters:
key
- Property namevalue
- Property valueAn import value may have properties that are distinct from the properties of its parent item. A typical example is an item that represents an email, in which case the values are the email body plus any attachments of the email. In such a scenario each value that represent an attachment may additionally specify meta data properties such as the file name and file type.
-
-