public class MariaDbValueObject extends Object implements ValueObject
TINYINT1_IS_BIT, YEAR_IS_DATE_TYPE
Constructor and Description |
---|
MariaDbValueObject(byte[] rawBytes,
ColumnInformation columnInfo,
boolean isBinaryEncoded,
Options options)
Constructor.
|
MariaDbValueObject(byte[] rawBytes,
ColumnInformation columnInfo,
Options options)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
BigDecimal |
getBigDecimal()
Get BigDecimal from rax data.
|
BigInteger |
getBigInteger()
Get BigInteger from raw data.
|
InputStream |
getBinaryInputStream()
Get binaryInputStream value from raw data.
|
Blob |
getBlob()
Get Blob from raw data
|
boolean |
getBoolean()
Get boolean value from raw data.
|
byte |
getByte()
Get byte from raw data.
|
byte[] |
getBytes() |
Clob |
getClob()
Get Clob from raw data
|
Date |
getDate(Calendar cal)
Get date from raw data.
|
int |
getDisplayLength()
Data length.
|
double |
getDouble()
Get double value from raw data.
|
float |
getFloat()
Get float from raw data.
|
InputStream |
getInputStream()
Get inputStream value from raw data.
|
int |
getInt()
Get int from raw data.
|
long |
getLong()
Get long from raw data.
|
Object |
getObject(int datatypeMappingFlags,
Calendar cal)
Get object value.
|
short |
getShort()
Get short from raw data.
|
String |
getString() |
String |
getString(Calendar cal)
Get String from raw data.
|
Time |
getTime(Calendar cal)
Get time from raw data.
|
Timestamp |
getTimestamp(Calendar cal)
Get timeStamp from raw data.
|
boolean |
isNull()
Is data null.
|
public MariaDbValueObject(byte[] rawBytes, ColumnInformation columnInfo, Options options)
rawBytes
- raw datacolumnInfo
- column informationoptions
- session optionspublic MariaDbValueObject(byte[] rawBytes, ColumnInformation columnInfo, boolean isBinaryEncoded, Options options)
rawBytes
- raw datacolumnInfo
- column informationisBinaryEncoded
- is text or binary encoded.options
- session optionspublic String getString()
getString
in interface ValueObject
public String getString(Calendar cal)
getString
in interface ValueObject
cal
- session calendarpublic byte getByte()
getByte
in interface ValueObject
public short getShort()
getShort
in interface ValueObject
public int getInt()
getInt
in interface ValueObject
public long getLong()
getLong
in interface ValueObject
public float getFloat()
getFloat
in interface ValueObject
public double getDouble()
getDouble
in interface ValueObject
public BigDecimal getBigDecimal()
getBigDecimal
in interface ValueObject
public byte[] getBytes()
getBytes
in interface ValueObject
public BigInteger getBigInteger()
getBigInteger
in interface ValueObject
public Date getDate(Calendar cal) throws ParseException
getDate
in interface ValueObject
cal
- session calendarParseException
- if raw data cannot be parsepublic Time getTime(Calendar cal) throws ParseException
getTime
in interface ValueObject
cal
- session calendarParseException
- if raw data cannot be parsepublic Timestamp getTimestamp(Calendar cal) throws ParseException
getTimestamp
in interface ValueObject
cal
- session calendar.ParseException
- if text value cannot be parsepublic InputStream getInputStream()
getInputStream
in interface ValueObject
public InputStream getBinaryInputStream()
getBinaryInputStream
in interface ValueObject
public boolean getBoolean()
getBoolean
in interface ValueObject
public boolean isNull()
isNull
in interface ValueObject
public int getDisplayLength()
public Blob getBlob()
getBlob
in interface ValueObject
public Clob getClob()
public Object getObject(int datatypeMappingFlags, Calendar cal) throws ParseException
getObject
in interface ValueObject
datatypeMappingFlags
- dataTypeflag (year is date or int, bit boolean or int, ...)cal
- session calendarParseException
- if data cannot be parseCopyright © 2015. All rights reserved.