public interface ValueMetaInterface extends Cloneable
PDI Field Type / Java Mapping
PDI data type | Type constant | Java data type | Description |
---|---|---|---|
String | TYPE_STRING | java.lang.String | A variable (unlimited) length text encoded in UTF-8 (Unicode) |
Integer | TYPE_INTEGER | java.lang.Long | A signed long (64-bit) integer |
Number | TYPE_NUMBER | java.lang.Double | A double precision floating point value |
Big Number | TYPE_BIGNUMBER | java.math.BigDecimal | An arbitrary (unlimited) precision number |
Date | TYPE_DATE | java.util.Date | A date-time value with millisecond precision |
Boolean | TYPE_BOOLEAN | java.lang.Boolean | A boolean value (true or false) |
Binary | TYPE_BINARY | java.lang.byte[ | An array of bytes that contain any type of binary data. |
Storage Types
In addition to the data type of a field, the storage type (getStorageType()/setStorageType()) is used to interpret the actual field value in a row array.
Type constant | Actual field data type | Interpretation |
---|---|---|
STORAGE_TYPE_NORMAL | As listed above | The value in the row array is of the type listed in the data type table above and represents the field's value directly. |
STORAGE_TYPE_BINARY_STRING | java.lang.byte[] | The field has been created using the “Lazy conversion” feature. This means it is a non-altered sequence of bytes as read from an external medium (usually a file). |
STORAGE_TYPE_INDEXED | java.lang.Integer | The row value is an integer index into a fixed array of possible values. The ValueMetaInterface object maintains the set of possible values in getIndex()/setIndex(). |
Modifier and Type | Field and Description |
---|---|
static int |
DEFAULT_INTEGER_LENGTH
Default integer length for hardcoded metadata integers
|
static int |
SORT_TYPE_ASCENDING
Indicating that the rows are not sorted ascending on this key
|
static int |
SORT_TYPE_DESCENDING
Indicating that the rows are sorted descending on this key
|
static int |
SORT_TYPE_NOT_SORTED
Indicating that the rows are not sorted on this key
|
static String[] |
sortTypeCodes
The Constant sortTypeCodes.
|
static int |
STORAGE_TYPE_BINARY_STRING
The storage type is binary: read from text but not yet converted to the requested target data type, for lazy
conversions.
|
static int |
STORAGE_TYPE_INDEXED
The storage type is indexed.
|
static int |
STORAGE_TYPE_NORMAL
The storage type is the same as the indicated value type
|
static String[] |
storageTypeCodes
The Constant storageTypeCodes.
|
static int |
TRIM_TYPE_BOTH
Indicating that the string content should be LEFT AND RIGHT trimmed if conversion is to occur to another data type
|
static int |
TRIM_TYPE_LEFT
Indicating that the string content should be LEFT trimmed if conversion is to occur to another data type
|
static int |
TRIM_TYPE_NONE
Indicating that the string content should NOT be trimmed if conversion is to occur to another data type
|
static int |
TRIM_TYPE_RIGHT
Indicating that the string content should be RIGHT trimmed if conversion is to occur to another data type
|
static int |
TYPE_BIGNUMBER
Value type indicating that the value contains a floating point precision number with arbitrary precision.
|
static int |
TYPE_BINARY
Value type indicating that the value contains binary data: BLOB, CLOB, ...
|
static int |
TYPE_BOOLEAN
Value type indicating that the value contains a boolean.
|
static int |
TYPE_DATE
Value type indicating that the value contains a Date.
|
static int |
TYPE_INET
Value type indicating that the value contains a Internet address
|
static int |
TYPE_INTEGER
Value type indicating that the value contains a long integer.
|
static int |
TYPE_NONE
Value type indicating that the value has no type set
|
static int |
TYPE_NUMBER
Value type indicating that the value contains a floating point double precision number.
|
static int |
TYPE_SERIALIZABLE
Value type indicating that the value contains an Object.
|
static int |
TYPE_STRING
Value type indicating that the value contains a text String.
|
static int |
TYPE_TIMESTAMP
Value type indicating that the value contains a date-time with nanosecond precision
|
static String[] |
typeCodes
The Constant typeCodes.
|
Modifier and Type | Method and Description |
---|---|
ValueMetaInterface |
clone() |
Object |
cloneValueData(Object object)
Clone value data.
|
int |
compare(Object data1,
Object data2)
Compare 2 values of the same data type
|
int |
compare(Object data1,
ValueMetaInterface meta2,
Object data2)
Compare 2 values of the same data type
|
Object |
convertBinaryStringToNativeType(byte[] binary)
Convert the given binary data to the actual data type.
- byte[] --> Long (Integer) - byte[] --> Double (Number) - byte[] --> BigDecimal (BigNumber) - byte[] --> Date (Date) - byte[] --> Boolean (Boolean) - byte[] --> byte[] (Binary) |
Object |
convertData(ValueMetaInterface meta2,
Object data2)
Convert the specified data to the data type specified in this object.
|
Object |
convertDataCompatible(ValueMetaInterface meta2,
Object data2)
Convert the specified data to the data type specified in this object.
|
Object |
convertDataFromString(String pol,
ValueMetaInterface convertMeta,
String nullif,
String ifNull,
int trim_type)
Convert the specified string to the data type specified in this object.
|
Object |
convertDataUsingConversionMetaData(Object data)
Convert an object to the data type specified in the conversion metadata
|
Object |
convertNormalStorageTypeToBinaryString(Object object)
Convert a normal storage type to a binary string object.
|
Object |
convertToBinaryStringStorageType(Object object)
Converts the specified data object to the binary string storage type.
|
Object |
convertToNormalStorageType(Object object)
Converts the specified data object to the normal storage type.
|
Value |
createOriginalValue(Object data)
Create an old-style value for backward compatibility reasons
|
void |
drawValue(PrimitiveGCInterface gc,
Object value)
This method draws the value using the supplied graphical context.
|
BigDecimal |
getBigNumber(Object object)
Convert the supplied data to a BigNumber
|
byte[] |
getBinary(Object object)
Convert the supplied data to binary data
|
byte[] |
getBinaryString(Object object)
convert the supplied data to a binary string representation (for writing text)
|
Boolean |
getBoolean(Object object)
Convert the supplied data to a Boolean
|
String |
getComments()
Gets the comments.
|
String |
getCompatibleString(Object object)
Convert the supplied data to a String compatible with version 2.5.
|
String |
getConversionMask()
Gets the conversion mask.
|
ValueMetaInterface |
getConversionMetadata()
This conversion metadata can be attached to a String object to see where it came from and with which mask it was
generated, the encoding, the local languages used, padding, etc.
|
String |
getCurrencySymbol()
Gets the currency symbol.
|
String |
getDatabaseColumnTypeDefinition(DatabaseInterface databaseInterface,
String tk,
String pk,
boolean use_autoinc,
boolean add_fieldname,
boolean add_cr)
Ask for suggestions as to how this plugin data type should be represented in the specified database interface
|
String |
getDataXML(Object value)
Returns an XML representation of the row data.
|
Date |
getDate(Object object)
Convert the supplied data to a Date
|
SimpleDateFormat |
getDateFormat()
Gets the date format.
|
Locale |
getDateFormatLocale()
Returns the locale from the date format.
|
TimeZone |
getDateFormatTimeZone() |
DecimalFormat |
getDecimalFormat()
Gets the decimal format.
|
DecimalFormat |
getDecimalFormat(boolean useBigDecimal)
Gets the decimal format.
|
String |
getDecimalSymbol()
Gets the decimal symbol.
|
String |
getGroupingSymbol()
Gets the grouping symbol.
|
Object[] |
getIndex()
Gets the index.
|
Long |
getInteger(Object object)
Convert the supplied data to an Integer
|
int |
getLength()
Gets the length.
|
String |
getMetaXML()
Returns an XML representation of the row metadata.
|
String |
getName()
Gets the name.
|
Object |
getNativeDataType(Object object)
This method gives you the native Java data type corresponding to the value meta-data.
|
Double |
getNumber(Object object)
Convert the supplied data to a Number
|
long |
getNumberOfBinaryStringConversions()
Returns the number of binary string to native data type conversions done with this object conversions
|
String |
getOrigin()
Gets the origin.
|
int |
getOriginalColumnType()
store original JDBC RecordSetMetaData for later use
|
String |
getOriginalColumnTypeName()
Gets the original column type name.
|
int |
getOriginalPrecision()
Gets the original precision.
|
int |
getOriginalScale()
Gets the original scale.
|
int |
getPrecision()
Gets the precision.
|
ValueMetaInterface |
getStorageMetadata()
Returns the storage Meta data that is needed for internal conversion from BinaryString or String to the specified
type.
|
int |
getStorageType()
Gets the storage type.
|
String |
getString(Object object)
Convert the supplied data to a String
|
String |
getStringEncoding()
Gets the string encoding.
|
int |
getTrimType()
Gets the trim type.
|
int |
getType()
Gets the type.
|
String |
getTypeDesc()
Return the type of a value in a textual form: "String", "Number", "Integer", "Boolean", "Date", ...
|
Object |
getValue(Node node)
Convert a data XML node to an Object that corresponds to the metadata.
|
Object |
getValueData(Value value)
Extracts the primitive data from an old style Value object
|
Object |
getValueFromResultSet(DatabaseInterface databaseInterface,
ResultSet resultSet,
int index)
Get a value from a result set column based on the current value metadata
|
ValueMetaInterface |
getValueFromSQLType(DatabaseMeta databaseMeta,
String name,
ResultSetMetaData rm,
int index,
boolean ignoreLength,
boolean lazyConversion)
Investigate JDBC result set metadata at the specified index.
|
int |
hashCode(Object object)
Calculate the hashcode of the specified data object
|
boolean |
isBigNumber()
Checks whether or not the value is a Big Number
|
boolean |
isBinary()
Checks whether or not this value is of type Binary
|
boolean |
isBoolean()
Checks whether or not this value is a boolean
|
boolean |
isCaseInsensitive()
Returns a true of the value object is case insensitive, false if it is case sensitive,
|
boolean |
isDate()
Checks whether or not this value is a Date
|
boolean |
isDateFormatLenient()
Returns true of the date format is leniant, false if it is strict.
|
boolean |
isInteger()
Checks whether or not this value is an Integer
|
boolean |
isLargeTextField()
Returns true if this is a large text field (CLOB, TEXT) with arbitrary length.
|
boolean |
isLenientStringToNumber() |
boolean |
isNull(Object data)
Determine if an object is null.
|
boolean |
isNumber()
Checks whether or not the value is a Number
|
boolean |
isNumeric()
Checks whether or not this Value is Numeric A Value is numeric if it is either of type Number or Integer
|
boolean |
isOriginalAutoIncrement()
Checks if is original auto increment.
|
int |
isOriginalNullable()
Checks if is original nullable.
|
boolean |
isOriginalSigned()
Checks if is original signed.
|
boolean |
isOutputPaddingEnabled()
Returns true if output padding is enabled (padding to specified length).
|
boolean |
isSerializableType()
Checks whether or not this value is of type Serializable
|
boolean |
isSingleByteEncoding() |
boolean |
isSortedDescending()
Returns whether or not the value should be sorted in descending order.
|
boolean |
isStorageBinaryString()
Checks if is storage binary string.
|
boolean |
isStorageIndexed()
Checks if is storage indexed.
|
boolean |
isStorageNormal()
Checks if is storage normal.
|
boolean |
isString()
Checks whether or not the value is a String.
|
Object |
readData(DataInputStream inputStream)
De-serialize data from an inputstream.
|
void |
readMetaData(DataInputStream inputStream)
Read the attributes of this particular value meta object from the specified input stream.
|
boolean |
requiresRealClone()
Returns true if the data type requires a real copy.
|
void |
setCaseInsensitive(boolean caseInsensitive)
Sets whether or not the value object is case sensitive.
|
void |
setComments(String comments)
Sets the comments for the object implementing the interface.
|
void |
setConversionMask(String conversionMask)
Sets the conversion mask.
|
void |
setConversionMetadata(ValueMetaInterface conversionMetadata)
Attach conversion metadata to a String object to see where it came from and with which mask it was generated, the
encoding, the local languages used, padding, etc.
|
void |
setCurrencySymbol(String currencySymbol)
Sets the currency symbol.
|
void |
setDateFormatLenient(boolean dateFormatLenient)
Set to true if the date formatting (parsing) is to be set to lenient.
|
void |
setDateFormatLocale(Locale dateFormatLocale)
Sets the locale of the date format.
|
void |
setDateFormatTimeZone(TimeZone dateFormatTimeZone) |
void |
setDecimalSymbol(String decimalSymbol)
Sets the decimal symbol.
|
void |
setGroupingSymbol(String groupingSymbol)
Sets the grouping symbol.
|
void |
setIndex(Object[] index)
Sets the index.
|
void |
setLargeTextField(boolean largeTextField)
Set to true if the this is to be a large text field (CLOB, TEXT) with arbitrary length.
|
void |
setLength(int length)
Sets the length.
|
void |
setLength(int length,
int precision)
Sets the length.
|
void |
setLenientStringToNumber(boolean lenientStringToNumber) |
void |
setName(String name)
Sets the name.
|
void |
setNumberOfBinaryStringConversions(long numberOfBinaryStringConversions)
Returns the number of binary string to native data type done with this object conversions to set.
|
void |
setOrigin(String origin)
Sets the origin.
|
void |
setOriginalAutoIncrement(boolean originalAutoIncrement)
Sets the original auto increment.
|
void |
setOriginalColumnType(int originalColumnType)
Sets the original column type.
|
void |
setOriginalColumnTypeName(String originalColumnTypeName)
Sets the original column type name.
|
void |
setOriginalNullable(int originalNullable)
Sets the original nullable.
|
void |
setOriginalPrecision(int originalPrecision)
Sets the original precision.
|
void |
setOriginalScale(int originalScale)
Sets the original scale.
|
void |
setOriginalSigned(boolean originalSigned)
Sets the original signed.
|
void |
setOutputPaddingEnabled(boolean outputPaddingEnabled)
Set to true if output padding is to be enabled (padding to specified length).
|
void |
setPrecision(int precision)
Sets the precision.
|
void |
setPreparedStatementValue(DatabaseMeta databaseMeta,
PreparedStatement preparedStatement,
int index,
Object data)
Set a value on a JDBC prepared statement on the specified position
|
void |
setSortedDescending(boolean sortedDescending)
Sets whether or not the value should be set in a descending order.
|
void |
setStorageMetadata(ValueMetaInterface storageMetadata)
Sets the storage meta data.
|
void |
setStorageType(int storageType)
Sets the storage type.
|
void |
setStringEncoding(String stringEncoding)
Sets the string encoding.
|
void |
setTrimType(int trimType)
Sets the trim type.
|
void |
setType(int type)
Deprecated.
This method is deprecated. The same code is still used underneath.
|
String |
toStringMeta()
a String text representation of this Value, optionally padded to the specified length
|
void |
writeData(DataOutputStream outputStream,
Object object)
Serialize the content of the specified data object to the outputStream.
|
void |
writeMeta(DataOutputStream outputStream)
Write the content of this class (metadata) to the specified output stream.
|
static final int TYPE_NONE
static final int TYPE_NUMBER
static final int TYPE_STRING
static final int TYPE_DATE
static final int TYPE_BOOLEAN
static final int TYPE_INTEGER
static final int TYPE_BIGNUMBER
static final int TYPE_SERIALIZABLE
static final int TYPE_BINARY
static final int TYPE_TIMESTAMP
static final int TYPE_INET
static final String[] typeCodes
static final int STORAGE_TYPE_NORMAL
static final int STORAGE_TYPE_BINARY_STRING
static final int STORAGE_TYPE_INDEXED
static final String[] storageTypeCodes
static final int SORT_TYPE_NOT_SORTED
static final int SORT_TYPE_ASCENDING
static final int SORT_TYPE_DESCENDING
static final String[] sortTypeCodes
static final int TRIM_TYPE_NONE
static final int TRIM_TYPE_LEFT
static final int TRIM_TYPE_RIGHT
static final int TRIM_TYPE_BOTH
static final int DEFAULT_INTEGER_LENGTH
String getName()
void setName(String name)
name
- the new nameint getLength()
void setLength(int length)
length
- the new lengthint getPrecision()
void setPrecision(int precision)
precision
- the new precisionvoid setLength(int length, int precision)
length
- the lengthprecision
- the precisionString getOrigin()
void setOrigin(String origin)
origin
- the new originString getComments()
void setComments(String comments)
comments
- the new commentsint getType()
@Deprecated void setType(int type)
type
- the new typeint getStorageType()
void setStorageType(int storageType)
storageType
- the new storage typeint getTrimType()
void setTrimType(int trimType)
trimType
- the new trim typeObject[] getIndex()
void setIndex(Object[] index)
index
- the new indexboolean isStorageNormal()
boolean isStorageIndexed()
boolean isStorageBinaryString()
String getConversionMask()
void setConversionMask(String conversionMask)
conversionMask
- the new conversion maskString getDecimalSymbol()
void setDecimalSymbol(String decimalSymbol)
decimalSymbol
- the new decimal symbolString getGroupingSymbol()
void setGroupingSymbol(String groupingSymbol)
groupingSymbol
- the new grouping symbolString getCurrencySymbol()
void setCurrencySymbol(String currencySymbol)
currencySymbol
- the new currency symbolSimpleDateFormat getDateFormat()
DecimalFormat getDecimalFormat()
DecimalFormat getDecimalFormat(boolean useBigDecimal)
useBigDecimal
- the use big decimalString getStringEncoding()
void setStringEncoding(String stringEncoding)
stringEncoding
- the new string encodingboolean isSingleByteEncoding()
boolean isNull(Object data) throws KettleValueException
data
- the object to testKettleValueException
- in case there is a conversion error (only thrown in case of lazy conversion)boolean isCaseInsensitive()
void setCaseInsensitive(boolean caseInsensitive)
caseInsensitive
- the caseInsensitive to setboolean isSortedDescending()
void setSortedDescending(boolean sortedDescending)
sortedDescending
- the sortedDescending to setboolean isOutputPaddingEnabled()
void setOutputPaddingEnabled(boolean outputPaddingEnabled)
outputPaddingEnabled
- Set to true if output padding is to be enabled (padding to specified length)boolean isLargeTextField()
void setLargeTextField(boolean largeTextField)
largeTextField
- Set to true if this is to be a large text field (CLOB, TEXT) with arbitrary length.boolean isDateFormatLenient()
setDateFormatLenient(boolean)
void setDateFormatLenient(boolean dateFormatLenient)
15 - (December = 12) = 3 = March.Set to false for stricter formatting validation.
dateFormatLenient
- true if the the date formatting (parsing) is to be set to lenient.Locale getDateFormatLocale()
void setDateFormatLocale(Locale dateFormatLocale)
dateFormatLocale
- the date format locale to setTimeZone getDateFormatTimeZone()
void setDateFormatTimeZone(TimeZone dateFormatTimeZone)
dateFormatTimeZone
- the date format time zone to setint getOriginalColumnType()
ResultSetMetaData
void setOriginalColumnType(int originalColumnType)
originalColumnType
- the new original column typeString getOriginalColumnTypeName()
void setOriginalColumnTypeName(String originalColumnTypeName)
originalColumnTypeName
- the new original column type nameint getOriginalPrecision()
void setOriginalPrecision(int originalPrecision)
originalPrecision
- the new original precisionint getOriginalScale()
void setOriginalScale(int originalScale)
originalScale
- the new original scaleboolean isOriginalAutoIncrement()
void setOriginalAutoIncrement(boolean originalAutoIncrement)
originalAutoIncrement
- the new original auto incrementint isOriginalNullable()
void setOriginalNullable(int originalNullable)
originalNullable
- the new original nullableboolean isOriginalSigned()
void setOriginalSigned(boolean originalSigned)
originalSigned
- the new original signedObject cloneValueData(Object object) throws KettleValueException
object
- the objectKettleValueException
- the kettle value exceptionString getCompatibleString(Object object) throws KettleValueException
KettleValueException
String getString(Object object) throws KettleValueException
KettleValueException
byte[] getBinaryString(Object object) throws KettleValueException
KettleValueException
Double getNumber(Object object) throws KettleValueException
KettleValueException
BigDecimal getBigNumber(Object object) throws KettleValueException
KettleValueException
Long getInteger(Object object) throws KettleValueException
KettleValueException
Date getDate(Object object) throws KettleValueException
KettleValueException
Boolean getBoolean(Object object) throws KettleValueException
KettleValueException
byte[] getBinary(Object object) throws KettleValueException
KettleValueException
ValueMetaInterface clone()
boolean isString()
boolean isDate()
boolean isBigNumber()
boolean isNumber()
boolean isBoolean()
boolean isSerializableType()
boolean isBinary()
boolean isInteger()
boolean isNumeric()
String getTypeDesc()
String toStringMeta()
void writeMeta(DataOutputStream outputStream) throws KettleFileException
outputStream
- the outputstream to write toKettleFileException
- in case a I/O error occursvoid writeData(DataOutputStream outputStream, Object object) throws KettleFileException
outputStream
- the outputstream to write toobject
- the data object to serializeKettleFileException
- in case a I/O error occursObject readData(DataInputStream inputStream) throws KettleFileException, KettleEOFException, SocketTimeoutException
inputStream
- the input stream to read fromKettleFileException
- in case a I/O error occursKettleEOFException
- When we have read all the data there is to readSocketTimeoutException
- In case there is a timeout (when set on a socket) during readingvoid readMetaData(DataInputStream inputStream) throws KettleFileException, KettleEOFException
inputStream
- the input stream to read fromKettleFileException
- In case there was a IO problemKettleEOFException
- If we reached the end of the streamint compare(Object data1, Object data2) throws KettleValueException
data1
- the first valuedata2
- the second valueKettleValueException
- In case we get conversion errorsint compare(Object data1, ValueMetaInterface meta2, Object data2) throws KettleValueException
data1
- the first valuemeta2
- the second value's metadatadata2
- the second valueKettleValueException
- In case we get conversion errorsObject convertData(ValueMetaInterface meta2, Object data2) throws KettleValueException
meta2
- the metadata of the object to be converteddata2
- the data of the object to be convertedKettleValueException
- in case there is a data conversion errorObject convertDataCompatible(ValueMetaInterface meta2, Object data2) throws KettleValueException
meta2
- the metadata of the object to be converteddata2
- the data of the object to be convertedKettleValueException
- in case there is a data conversion errorObject convertDataUsingConversionMetaData(Object data) throws KettleValueException
data
- The dataKettleValueException
- in case there is a conversion error.Object convertDataFromString(String pol, ValueMetaInterface convertMeta, String nullif, String ifNull, int trim_type) throws KettleValueException
pol
- the string to be convertedconvertMeta
- the metadata of the object (only string type) to be convertednullif
- set the object to null if pos equals nullif (IgnoreCase)ifNull
- set the object to ifNull when pol is empty or nulltrim_type
- the trim type to be used (ValueMetaInterface.TRIM_TYPE_XXX)KettleValueException
- in case there is a data conversion errorObject convertToNormalStorageType(Object object) throws KettleValueException
object
- the data object to convertKettleValueException
- In case there is a data conversion error.Object convertBinaryStringToNativeType(byte[] binary) throws KettleValueException
binary
- the binary data read from file or databaseKettleValueException
- in case there is a data conversion errorObject convertNormalStorageTypeToBinaryString(Object object) throws KettleValueException
object
- The object expressed in a normal storage typeKettleValueException
- in case there is a data conversion errorObject convertToBinaryStringStorageType(Object object) throws KettleValueException
object
- the data object to convertKettleValueException
- In case there is a data conversion error.int hashCode(Object object) throws KettleValueException
object
- the data value to calculate a hashcode forKettleValueException
- in case there is a data conversion errorValue createOriginalValue(Object data) throws KettleValueException
data
- the data to store in the valueKettleValueException
- in case there is a data conversion problemObject getValueData(Value value) throws KettleValueException
value
- the old style Value objectKettleValueException
- case there is a data conversion problemValueMetaInterface getStorageMetadata()
void setStorageMetadata(ValueMetaInterface storageMetadata)
storageMetadata
- the storage Meta data that is needed for internal conversion from BinaryString or String to the specified
type. This storage Meta data object survives cloning and should travel through the transformation
unchanged as long as the data type remains the same.ValueMetaInterface getConversionMetadata()
void setConversionMetadata(ValueMetaInterface conversionMetadata)
conversionMetadata
- the conversionMetadata to setString getMetaXML() throws IOException
IOException
- Thrown in case there is an (Base64/GZip) decoding problemString getDataXML(Object value) throws IOException
value
- The data to serialize as XMLIOException
- Thrown in case there is an (Base64/GZip) decoding problemObject getValue(Node node) throws KettleException
node
- the node to retrieve the data value fromKettleException
- thrown in case there is a problem with the XML to object conversionlong getNumberOfBinaryStringConversions()
void setNumberOfBinaryStringConversions(long numberOfBinaryStringConversions)
numberOfBinaryStringConversions
- the number of binary string to native data type done with this object conversions to setboolean requiresRealClone()
boolean isLenientStringToNumber()
void setLenientStringToNumber(boolean lenientStringToNumber)
lenientStringToNumber
- Set to if string to number conversion is to occur in a lenient fashion, parsing numbers successfully until
a non-numeric character is found.void drawValue(PrimitiveGCInterface gc, Object value) throws KettleValueException
gc
- The graphical context to draw on.KettleValueException
ValueMetaInterface getValueFromSQLType(DatabaseMeta databaseMeta, String name, ResultSetMetaData rm, int index, boolean ignoreLength, boolean lazyConversion) throws KettleDatabaseException
databaseMeta
- the database metadata to reference capabilities and so on.name
- The name of the new valuerm
- The result metadata to investigateindex
- The index to look at (1-based)ignoreLength
- Don't look at the lengthlazyConversion
- use lazy conversionKettleDatabaseException
- In case something went wrong.Object getValueFromResultSet(DatabaseInterface databaseInterface, ResultSet resultSet, int index) throws KettleDatabaseException
databaseInterface
- the database metadata to useresultSet
- The JDBC result set to read fromindex
- The column index (0-based)KettleDatabaseException
- in case something goes wrong.void setPreparedStatementValue(DatabaseMeta databaseMeta, PreparedStatement preparedStatement, int index, Object data) throws KettleDatabaseException
databaseMeta
- the database metadata to referencepreparedStatement
- The prepared statementindex
- the column index (1-based)data
- the value to setKettleDatabaseException
- in case something goes wrongObject getNativeDataType(Object object) throws KettleValueException
object
- The input dataKettleValueException
- in case there is an unexpected data conversion error.String getDatabaseColumnTypeDefinition(DatabaseInterface databaseInterface, String tk, String pk, boolean use_autoinc, boolean add_fieldname, boolean add_cr)
databaseInterface
- The database type/dialect to get the column type definition fortk
- Is this a technical key field?pk
- Is this a primary key field?use_autoinc
- Use auto-increment?add_fieldname
- add the fieldname to the column type definition?add_cr
- add a cariage return to the string?