|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.pentaho.di.core.row.ValueMeta
public class ValueMeta
| Field Summary | |
|---|---|
static String |
DEFAULT_DATE_FORMAT_MASK
|
static boolean |
EMPTY_STRING_AND_NULL_ARE_DIFFERENT
|
static String[] |
SINGLE_BYTE_ENCODINGS
|
static String[] |
trimTypeCode
The trim type codes |
static String[] |
trimTypeDesc
The trim description |
static String |
XML_DATA_TAG
|
static String |
XML_META_TAG
|
| Fields inherited from interface org.pentaho.di.core.row.ValueMetaInterface |
|---|
DEFAULT_INTEGER_LENGTH, SORT_TYPE_ASCENDING, SORT_TYPE_DESCENDING, SORT_TYPE_NOT_SORTED, sortTypeCodes, STORAGE_TYPE_BINARY_STRING, STORAGE_TYPE_INDEXED, STORAGE_TYPE_NORMAL, storageTypeCodes, TRIM_TYPE_BOTH, TRIM_TYPE_LEFT, TRIM_TYPE_NONE, TRIM_TYPE_RIGHT, TYPE_BIGNUMBER, TYPE_BINARY, TYPE_BOOLEAN, TYPE_DATE, TYPE_INTEGER, TYPE_NONE, TYPE_NUMBER, TYPE_SERIALIZABLE, TYPE_STRING, typeCodes |
| Constructor Summary | |
|---|---|
ValueMeta()
|
|
ValueMeta(DataInputStream inputStream)
|
|
ValueMeta(Node node)
|
|
ValueMeta(String name)
|
|
ValueMeta(String name,
int type)
|
|
ValueMeta(String name,
int type,
int storageType)
|
|
ValueMeta(String name,
int type,
int length,
int precision)
|
|
| Method Summary | |
|---|---|
ValueMeta |
clone()
|
Object |
cloneValueData(Object object)
Clones the 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 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 data2)
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. |
static Boolean |
convertStringToBoolean(String string)
|
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 |
static String[] |
getAllTypes()
Get an array of String describing the possible types a Value can have. |
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 |
getDataXML(Object object)
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. |
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. |
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. |
static int |
getStorageType(String desc)
Convert the String description of a storage type to an integer type. |
static String |
getStorageTypeCode(int storageType)
|
String |
getStorageTypeDesc()
Return the storage type of a value in a textual form: "normal", "binary-string", "indexes" |
String |
getString(Object object)
Convert the supplied data to a String |
String |
getStringEncoding()
Gets the string encoding. |
int |
getTrimType()
Gets the trim type. |
static int |
getTrimTypeByCode(String tt)
|
static int |
getTrimTypeByDesc(String tt)
|
static String |
getTrimTypeCode(int i)
|
static String[] |
getTrimTypeCodes()
|
static String |
getTrimTypeDesc(int i)
|
static String[] |
getTrimTypeDescriptions()
|
int |
getType()
Gets the type. |
static int |
getType(String desc)
Convert the String description of a type to an integer type. |
String |
getTypeDesc()
Return the type of a value in a textual form: "String", "Number", "Integer", "Boolean", "Date", ... |
static String |
getTypeDesc(int type)
TODO: change Desc to Code all over the place. |
static String[] |
getTypes()
get an array of String describing the possible types a Value can have. |
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 |
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 |
isBigNumberFormatting()
|
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 |
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 |
static boolean |
isNumeric(int t)
Checks whether or not the specified type is either Integer or Number |
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 |
isSortedAscending()
|
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. |
boolean |
requiresRealClone()
Returns true if the data type requires a real copy. |
void |
setBigNumberFormatting(boolean bigNumberFormatting)
|
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 |
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 |
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 |
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 encoding)
Sets the string encoding. |
void |
setTrimType(int trimType)
Sets the trim type. |
void |
setType(int type)
Sets the type. |
String |
toString()
|
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. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final String DEFAULT_DATE_FORMAT_MASK
public static final String XML_META_TAG
public static final String XML_DATA_TAG
public static final boolean EMPTY_STRING_AND_NULL_ARE_DIFFERENT
public static final String[] trimTypeCode
public static final String[] trimTypeDesc
public static final String[] SINGLE_BYTE_ENCODINGS
| Constructor Detail |
|---|
public ValueMeta()
public ValueMeta(String name)
public ValueMeta(String name,
int type)
public ValueMeta(String name,
int type,
int storageType)
public ValueMeta(String name,
int type,
int length,
int precision)
public ValueMeta(DataInputStream inputStream)
throws KettleFileException,
KettleEOFException
KettleFileException
KettleEOFException
public ValueMeta(Node node)
throws KettleException
KettleException| Method Detail |
|---|
public ValueMeta clone()
clone in interface ValueMetaInterfaceclone in class Objectpublic String getComments()
ValueMetaInterface
getComments in interface ValueMetaInterfacepublic void setComments(String comments)
ValueMetaInterface
setComments in interface ValueMetaInterfacecomments - the comments to setpublic Object[] getIndex()
ValueMetaInterface
getIndex in interface ValueMetaInterfacepublic void setIndex(Object[] index)
ValueMetaInterface
setIndex in interface ValueMetaInterfaceindex - the index to setpublic int getLength()
ValueMetaInterface
getLength in interface ValueMetaInterfacepublic void setLength(int length)
ValueMetaInterface
setLength in interface ValueMetaInterfacelength - the length to set
public void setLength(int length,
int precision)
ValueMetaInterface
setLength in interface ValueMetaInterfacelength - the length to setprecision - the precisionpublic String getName()
ValueMetaInterface
getName in interface ValueMetaInterfacepublic void setName(String name)
ValueMetaInterface
setName in interface ValueMetaInterfacename - the name to setpublic String getOrigin()
ValueMetaInterface
getOrigin in interface ValueMetaInterfacepublic void setOrigin(String origin)
ValueMetaInterface
setOrigin in interface ValueMetaInterfaceorigin - the origin to setpublic int getPrecision()
ValueMetaInterface
getPrecision in interface ValueMetaInterfacepublic void setPrecision(int precision)
ValueMetaInterface
setPrecision in interface ValueMetaInterfaceprecision - the precision to setpublic int getStorageType()
ValueMetaInterface
getStorageType in interface ValueMetaInterfacepublic void setStorageType(int storageType)
ValueMetaInterface
setStorageType in interface ValueMetaInterfacestorageType - the storageType to setpublic boolean isStorageNormal()
ValueMetaInterface
isStorageNormal in interface ValueMetaInterfacepublic boolean isStorageIndexed()
ValueMetaInterface
isStorageIndexed in interface ValueMetaInterfacepublic boolean isStorageBinaryString()
ValueMetaInterface
isStorageBinaryString in interface ValueMetaInterfacepublic int getType()
ValueMetaInterface
getType in interface ValueMetaInterfacepublic void setType(int type)
ValueMetaInterface
setType in interface ValueMetaInterfacetype - the type to setpublic String getConversionMask()
ValueMetaInterface
getConversionMask in interface ValueMetaInterfacepublic void setConversionMask(String conversionMask)
ValueMetaInterface
setConversionMask in interface ValueMetaInterfaceconversionMask - the conversionMask to setpublic String getStringEncoding()
ValueMetaInterface
getStringEncoding in interface ValueMetaInterfacepublic void setStringEncoding(String encoding)
ValueMetaInterface
setStringEncoding in interface ValueMetaInterfaceencoding - the encoding to setpublic String getDecimalSymbol()
ValueMetaInterface
getDecimalSymbol in interface ValueMetaInterfacepublic void setDecimalSymbol(String decimalSymbol)
ValueMetaInterface
setDecimalSymbol in interface ValueMetaInterfacedecimalSymbol - the decimalSymbol to setpublic String getGroupingSymbol()
ValueMetaInterface
getGroupingSymbol in interface ValueMetaInterfacepublic void setGroupingSymbol(String groupingSymbol)
ValueMetaInterface
setGroupingSymbol in interface ValueMetaInterfacegroupingSymbol - the groupingSymbol to setpublic String getCurrencySymbol()
ValueMetaInterface
getCurrencySymbol in interface ValueMetaInterfacepublic void setCurrencySymbol(String currencySymbol)
ValueMetaInterface
setCurrencySymbol in interface ValueMetaInterfacecurrencySymbol - the currencySymbol to setpublic boolean isCaseInsensitive()
ValueMetaInterface
isCaseInsensitive in interface ValueMetaInterfacepublic void setCaseInsensitive(boolean caseInsensitive)
ValueMetaInterface
setCaseInsensitive in interface ValueMetaInterfacecaseInsensitive - the caseInsensitive to setpublic boolean isSortedDescending()
ValueMetaInterface
isSortedDescending in interface ValueMetaInterfacepublic void setSortedDescending(boolean sortedDescending)
ValueMetaInterface
setSortedDescending in interface ValueMetaInterfacesortedDescending - the sortedDescending to setpublic boolean isOutputPaddingEnabled()
ValueMetaInterface
isOutputPaddingEnabled in interface ValueMetaInterfacepublic void setOutputPaddingEnabled(boolean outputPaddingEnabled)
ValueMetaInterface
setOutputPaddingEnabled in interface ValueMetaInterfaceoutputPaddingEnabled - Set to true if output padding is to be enabled (padding to specified length)public boolean isLargeTextField()
ValueMetaInterface
isLargeTextField in interface ValueMetaInterfacepublic void setLargeTextField(boolean largeTextField)
ValueMetaInterface
setLargeTextField in interface ValueMetaInterfacelargeTextField - Set to true if this is to be a large text field (CLOB, TEXT) with arbitrary length.public boolean isDateFormatLenient()
ValueMetaInterfaceValueMetaInterface.setDateFormatLenient(boolean)
isDateFormatLenient in interface ValueMetaInterfacepublic void setDateFormatLenient(boolean dateFormatLenient)
ValueMetaInterface15 - (December = 12) = 3 = March.Set to false for stricter formatting validation.
setDateFormatLenient in interface ValueMetaInterfacedateFormatLenient - the dateFormatLenient to setpublic Locale getDateFormatLocale()
ValueMetaInterface
getDateFormatLocale in interface ValueMetaInterfacepublic void setDateFormatLocale(Locale dateFormatLocale)
ValueMetaInterface
setDateFormatLocale in interface ValueMetaInterfacedateFormatLocale - the dateFormatLocale to setpublic SimpleDateFormat getDateFormat()
ValueMetaInterface
getDateFormat in interface ValueMetaInterfacepublic DecimalFormat getDecimalFormat()
ValueMetaInterface
getDecimalFormat in interface ValueMetaInterfacepublic DecimalFormat getDecimalFormat(boolean useBigDecimal)
ValueMetaInterface
getDecimalFormat in interface ValueMetaInterfaceuseBigDecimal - the use big decimal
public static Boolean convertStringToBoolean(String string)
public Object convertToNormalStorageType(Object object)
throws KettleValueException
convertToNormalStorageType in interface ValueMetaInterfaceobject - the data object to convert
KettleValueException - In case there is a data conversion error.
public Object convertToBinaryStringStorageType(Object object)
throws KettleValueException
convertToBinaryStringStorageType in interface ValueMetaInterfaceobject - the data object to convert
KettleValueException - In case there is a data conversion error.
public Object convertBinaryStringToNativeType(byte[] binary)
throws KettleValueException
convertBinaryStringToNativeType in interface ValueMetaInterfacebinary -
KettleValueException
public Object convertNormalStorageTypeToBinaryString(Object object)
throws KettleValueException
ValueMetaInterface
convertNormalStorageTypeToBinaryString in interface ValueMetaInterfaceobject - The object expressed in a normal storage type
KettleValueException - in case there is a data conversion error
public Object cloneValueData(Object object)
throws KettleValueException
cloneValueData in interface ValueMetaInterfaceobject - the object
KettleValueException - the kettle value exception
public String getCompatibleString(Object object)
throws KettleValueException
ValueMetaInterface
getCompatibleString in interface ValueMetaInterfaceKettleValueException
public String getString(Object object)
throws KettleValueException
ValueMetaInterface
getString in interface ValueMetaInterfaceKettleValueException
public Double getNumber(Object object)
throws KettleValueException
ValueMetaInterface
getNumber in interface ValueMetaInterfaceKettleValueException
public Long getInteger(Object object)
throws KettleValueException
ValueMetaInterface
getInteger in interface ValueMetaInterfaceKettleValueException
public BigDecimal getBigNumber(Object object)
throws KettleValueException
ValueMetaInterface
getBigNumber in interface ValueMetaInterfaceKettleValueException
public Boolean getBoolean(Object object)
throws KettleValueException
ValueMetaInterface
getBoolean in interface ValueMetaInterfaceKettleValueException
public Date getDate(Object object)
throws KettleValueException
ValueMetaInterface
getDate in interface ValueMetaInterfaceKettleValueException
public byte[] getBinary(Object object)
throws KettleValueException
ValueMetaInterface
getBinary in interface ValueMetaInterfaceKettleValueException
public byte[] getBinaryString(Object object)
throws KettleValueException
ValueMetaInterface
getBinaryString in interface ValueMetaInterfaceKettleValueExceptionpublic boolean isString()
isString in interface ValueMetaInterfacepublic boolean isDate()
isDate in interface ValueMetaInterfacepublic boolean isBigNumber()
isBigNumber in interface ValueMetaInterfacepublic boolean isNumber()
isNumber in interface ValueMetaInterfacepublic boolean isBoolean()
isBoolean in interface ValueMetaInterfacepublic boolean isSerializableType()
isSerializableType in interface ValueMetaInterfacepublic boolean isBinary()
isBinary in interface ValueMetaInterfacepublic boolean isInteger()
isInteger in interface ValueMetaInterfacepublic boolean isNumeric()
isNumeric in interface ValueMetaInterfacepublic static final boolean isNumeric(int t)
t - the type to check
public boolean isSortedAscending()
public String getTypeDesc()
getTypeDesc in interface ValueMetaInterfacepublic String getStorageTypeDesc()
public String toString()
toString in class Objectpublic String toStringMeta()
toStringMeta in interface ValueMetaInterface
public void writeData(DataOutputStream outputStream,
Object object)
throws KettleFileException
ValueMetaInterface
writeData in interface ValueMetaInterfaceoutputStream - the outputstream to write toobject - the data object to serialize
KettleFileException - in case a I/O error occurs
public Object readData(DataInputStream inputStream)
throws KettleFileException,
KettleEOFException,
SocketTimeoutException
ValueMetaInterface
readData in interface ValueMetaInterfaceinputStream - the input stream to read from
KettleFileException - in case a I/O error occurs
KettleEOFException - When we have read all the data there is to read
SocketTimeoutException - In case there is a timeout (when set on a socket) during reading
public void writeMeta(DataOutputStream outputStream)
throws KettleFileException
ValueMetaInterface
writeMeta in interface ValueMetaInterfaceoutputStream - the outputstream to write to
KettleFileException - in case a I/O error occurs
public String getMetaXML()
throws IOException
ValueMetaInterface
getMetaXML in interface ValueMetaInterfaceIOException - Thrown in case there is an (Base64/GZip) decoding problem
public String getDataXML(Object object)
throws IOException
ValueMetaInterface
getDataXML in interface ValueMetaInterfaceobject - The data to serialize as XML
IOException - Thrown in case there is an (Base64/GZip) decoding problem
public Object getValue(Node node)
throws KettleException
getValue in interface ValueMetaInterfacenode - the node to retrieve the data value from
IOException - thrown in case there is a problem with the XML to object conversion
KettleException - thrown in case there is a problem with the XML to object conversionpublic static final String[] getTypes()
public static final String[] getAllTypes()
public static final String getTypeDesc(int type)
type - the type
public static final int getType(String desc)
desc - The description of the type to convert
public static final int getStorageType(String desc)
desc - The description of the storage type to convert
public static final String getStorageTypeCode(int storageType)
public boolean isNull(Object data)
throws KettleValueException
isNull in interface ValueMetaInterfacedata - the object to test
KettleValueException - in case there is a conversion error (only thrown in case of lazy conversion)
public int compare(Object data1,
Object data2)
throws KettleValueException
compare in interface ValueMetaInterfacedata1 - the first valuedata2 - the second value
KettleValueException - In case we get conversion errors
public int compare(Object data1,
ValueMetaInterface meta2,
Object data2)
throws KettleValueException
compare in interface ValueMetaInterfacedata1 - the first valuemeta2 - the second value's metadatadata2 - the second value
KettleValueException - In case we get conversion errors
public Object convertData(ValueMetaInterface meta2,
Object data2)
throws KettleValueException
convertData in interface ValueMetaInterfacemeta2 - the metadata of the object to be converteddata2 - the data of the object to be converted
KettleValueException - in case there is a data conversion error
public Object convertDataCompatible(ValueMetaInterface meta2,
Object data2)
throws KettleValueException
convertDataCompatible in interface ValueMetaInterfacemeta2 - the metadata of the object to be converteddata2 - the data of the object to be converted
KettleValueException - in case there is a data conversion error
public Object convertDataUsingConversionMetaData(Object data2)
throws KettleValueException
convertDataUsingConversionMetaData in interface ValueMetaInterfacedata - The data
KettleValueException - in case there is a conversion error.
public Object convertDataFromString(String pol,
ValueMetaInterface convertMeta,
String nullIf,
String ifNull,
int trim_type)
throws KettleValueException
convertDataFromString in interface ValueMetaInterfacepol - 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 error
public int hashCode(Object object)
throws KettleValueException
hashCode in interface ValueMetaInterfaceobject - the data value to calculate a hashcode for
KettleValueException
public Value createOriginalValue(Object data)
throws KettleValueException
createOriginalValue in interface ValueMetaInterfacedata - the data to store in the value
KettleValueException - case there is a data conversion problem
public Object getValueData(Value value)
throws KettleValueException
getValueData in interface ValueMetaInterfacevalue - the old style Value object
KettleValueException - case there is a data conversion problempublic ValueMetaInterface getStorageMetadata()
ValueMetaInterface
getStorageMetadata in interface ValueMetaInterfacepublic void setStorageMetadata(ValueMetaInterface storageMetadata)
ValueMetaInterface
setStorageMetadata in interface ValueMetaInterfacestorageMetadata - the storageMetadata to setpublic int getTrimType()
ValueMetaInterface
getTrimType in interface ValueMetaInterfacepublic void setTrimType(int trimType)
ValueMetaInterface
setTrimType in interface ValueMetaInterfacetrimType - the trimType to setpublic static final int getTrimTypeByCode(String tt)
public static final int getTrimTypeByDesc(String tt)
public static final String getTrimTypeCode(int i)
public static final String getTrimTypeDesc(int i)
public ValueMetaInterface getConversionMetadata()
ValueMetaInterface
getConversionMetadata in interface ValueMetaInterfacepublic void setConversionMetadata(ValueMetaInterface conversionMetadata)
ValueMetaInterface
setConversionMetadata in interface ValueMetaInterfaceconversionMetadata - the conversionMetadata to setpublic boolean isSingleByteEncoding()
isSingleByteEncoding in interface ValueMetaInterfacepublic long getNumberOfBinaryStringConversions()
ValueMetaInterface
getNumberOfBinaryStringConversions in interface ValueMetaInterfacepublic void setNumberOfBinaryStringConversions(long numberOfBinaryStringConversions)
ValueMetaInterface
setNumberOfBinaryStringConversions in interface ValueMetaInterfacenumberOfBinaryStringConversions - the number of binary string to native data type done with this object conversions to setpublic boolean isOriginalAutoIncrement()
ValueMetaInterface
isOriginalAutoIncrement in interface ValueMetaInterfacepublic void setOriginalAutoIncrement(boolean originalAutoIncrement)
ValueMetaInterface
setOriginalAutoIncrement in interface ValueMetaInterfaceoriginalAutoIncrement - the new original auto incrementpublic int getOriginalColumnType()
ValueMetaInterface
getOriginalColumnType in interface ValueMetaInterfaceResultSetMetaDatapublic void setOriginalColumnType(int originalColumnType)
ValueMetaInterface
setOriginalColumnType in interface ValueMetaInterfaceoriginalColumnType - the new original column typepublic String getOriginalColumnTypeName()
ValueMetaInterface
getOriginalColumnTypeName in interface ValueMetaInterfacepublic void setOriginalColumnTypeName(String originalColumnTypeName)
ValueMetaInterface
setOriginalColumnTypeName in interface ValueMetaInterfaceoriginalColumnTypeName - the new original column type namepublic int isOriginalNullable()
ValueMetaInterface
isOriginalNullable in interface ValueMetaInterfacepublic void setOriginalNullable(int originalNullable)
ValueMetaInterface
setOriginalNullable in interface ValueMetaInterfaceoriginalNullable - the new original nullablepublic int getOriginalPrecision()
ValueMetaInterface
getOriginalPrecision in interface ValueMetaInterfacepublic void setOriginalPrecision(int originalPrecision)
ValueMetaInterface
setOriginalPrecision in interface ValueMetaInterfaceoriginalPrecision - the new original precisionpublic int getOriginalScale()
ValueMetaInterface
getOriginalScale in interface ValueMetaInterfacepublic void setOriginalScale(int originalScale)
ValueMetaInterface
setOriginalScale in interface ValueMetaInterfaceoriginalScale - the new original scalepublic boolean isOriginalSigned()
ValueMetaInterface
isOriginalSigned in interface ValueMetaInterfacepublic void setOriginalSigned(boolean originalSigned)
ValueMetaInterface
setOriginalSigned in interface ValueMetaInterfaceoriginalSigned - the new original signedpublic boolean isBigNumberFormatting()
public void setBigNumberFormatting(boolean bigNumberFormatting)
bigNumberFormatting - the bigNumberFormatting flag to set : true if BigNumbers of formatted as wellpublic static String[] getTrimTypeCodes()
public static String[] getTrimTypeDescriptions()
public boolean requiresRealClone()
ValueMetaInterface
requiresRealClone in interface ValueMetaInterface
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||