|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sap.ip.me.api.persist.meta.AttributeType
Class provides persistence type mapping.
Field Summary | |
static AttributeType |
BIGDECIMAL
BIGDECIMAL AttributeType is mapping java.math.BigDecimal. |
static AttributeType |
BIGINTEGER
BIGINTEGER AttributeType is mapping java.math.BigInteger. |
static AttributeType |
BINARY
Describes binary large objects (BLOB's) by mapping byte[] Maximum Size is limited by the available memory. |
static AttributeType |
BOOLEAN
BOOLEAN AttributeType maps instances of java.lang.Boolean |
static AttributeType |
BYTE
BYTE AttributeType maps instances of java.lang.Byte |
static java.lang.String |
CODE_PAGE
|
static AttributeType |
DATE
DATE AttributeType handles instances of java.util.Calendar. |
static AttributeType |
DECIMAL
Deprecated. Use BIGDECIMAL instead if precision of DOUBLE is not sufficient. |
static AttributeType |
DOUBLE
DOUBLE AttributeType maps instances of java.lang.Double |
static AttributeType |
FLOAT
FLOAT AttributeType maps instances of java.lang.Float |
static AttributeType |
INTEGER
INTEGER AttributeType maps instances of java.lang.Integer |
java.lang.Class |
javaType
Description of the Field |
int |
jdbcType
Description of the Field |
static AttributeType |
LONG
LONG AttributeType maps instances of java.lang.Long |
static java.lang.String |
NULL_STR
|
static AttributeType |
SHORT
SHORT AttributeType maps instances of java.lang.Short |
static AttributeType |
SQLDATE
SQLDATE AttributeType is mapping java.sql.Date |
static AttributeType |
SQLTIME
SQLTIME AttributeType is mapping java.sql.Time |
java.lang.String |
sqlType
Description of the Field |
static AttributeType |
STRING
STRING AttributeType maps instances of java.lang.String |
Constructor Summary | |
protected |
AttributeType(java.lang.Class javaType,
int jdbcType,
java.lang.String sqlType)
Constructor for the AttributeType object |
Method Summary | |
protected static int |
byteToInt(byte[] arr,
int off)
|
protected static int |
byteToLength(byte[] arr,
int off)
|
protected static long |
byteToLong(byte[] arr,
int off)
|
protected static int |
byteToShort(byte[] arr,
int off)
|
java.lang.Object |
cloneMutable(java.lang.Object o)
provide clone instance, if o is mutable class |
abstract int |
compare(byte[] b1,
byte[] b2)
|
int |
compare(byte[] row0,
byte[] row1,
int off,
int len)
|
int |
compare(byte[] row,
int off,
byte[] field)
|
protected int |
compare(java.util.Date d1,
java.util.Date d2)
|
protected int |
compare(long i1,
long i2)
|
abstract int |
compare(java.lang.Object o1,
java.lang.Object o2)
Description of the Method |
boolean |
contains(byte[] row,
int off,
byte[] field)
|
abstract boolean |
contains(byte[] b,
java.lang.Object o)
|
boolean |
equals(byte[] row,
int off,
byte[] field)
|
boolean |
equals(byte[] b,
java.lang.Object o)
|
boolean |
equals(java.lang.Object o)
Description of the Method |
static AttributeType |
forInstanceId(int id)
|
abstract java.lang.Object |
getDefaultValue(int len,
int dec)
|
int |
getInstanceId()
|
boolean |
greaterThan(byte[] row,
int off,
byte[] field)
|
boolean |
greaterThan(byte[] b,
java.lang.Object o)
|
protected static void |
intToByte(byte[] arr,
int off,
int val)
|
abstract boolean |
isValidType(java.lang.Object obj)
check if the given objects has the rigth type |
protected static void |
lengthToByte(byte[] arr,
int off,
int len)
|
protected static void |
longToByte(byte[] arr,
int off,
long val)
|
boolean |
lowerThan(byte[] row,
int off,
byte[] field)
|
boolean |
lowerThan(byte[] b,
java.lang.Object o)
|
boolean |
notEqual(byte[] row,
int off,
byte[] field)
|
boolean |
notEqual(byte[] b,
java.lang.Object o)
|
protected static long |
parseSignedLong(char[] in,
int inOff,
int inLen)
|
protected static void |
shortToByte(byte[] arr,
int off,
int val)
|
boolean |
startsWith(byte[] row,
int off,
byte[] field)
|
abstract boolean |
startWith(byte[] b,
java.lang.Object o)
|
abstract int |
toByte(byte[] arr,
int off,
java.lang.Object obj,
int len,
int dec)
This method converts the object to byte array representation. |
int |
toByte(char[] in,
int inOff,
int inLen,
byte[] out,
int outOff,
int outLen,
int outDec)
|
abstract int |
toByteLen(int len,
int dec)
|
java.lang.String |
toString()
Description of the Method |
abstract java.lang.Object |
toValue(byte[] arr,
int off)
This method convert the byte array representation to a value object. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final java.lang.String CODE_PAGE
public static final java.lang.String NULL_STR
public static final AttributeType STRING
public static final AttributeType INTEGER
public static final AttributeType SHORT
public static final AttributeType LONG
public static final AttributeType FLOAT
public static final AttributeType DOUBLE
public static final AttributeType BOOLEAN
public static final AttributeType BYTE
public static final AttributeType BINARY
public static final AttributeType DATE
public static final AttributeType DECIMAL
public static final AttributeType SQLDATE
public static final AttributeType SQLTIME
public static final AttributeType BIGDECIMAL
The length of your BIGDECIMAL attributes should not exceed 31 digits for best possible performance.
public static final AttributeType BIGINTEGER
Use with care, because instances of java.math.BigInteger have a high memory consumption. Use LONG instead if a precision of 18 digits is sufficient.
public final java.lang.Class javaType
public final int jdbcType
public final java.lang.String sqlType
Constructor Detail |
protected AttributeType(java.lang.Class javaType, int jdbcType, java.lang.String sqlType)
javaType
- Description of the ParameterjdbcType
- Description of the ParametersqlType
- Description of the ParameterMethod Detail |
public int getInstanceId()
getInstanceId
in interface InstanceIdProvider
public final boolean greaterThan(byte[] row, int off, byte[] field)
public int compare(byte[] row, int off, byte[] field)
public int compare(byte[] row0, byte[] row1, int off, int len)
public int toByte(char[] in, int inOff, int inLen, byte[] out, int outOff, int outLen, int outDec)
public final boolean lowerThan(byte[] row, int off, byte[] field)
public final boolean notEqual(byte[] row, int off, byte[] field)
public final boolean equals(byte[] row, int off, byte[] field)
public boolean contains(byte[] row, int off, byte[] field)
public boolean startsWith(byte[] row, int off, byte[] field)
protected static long parseSignedLong(char[] in, int inOff, int inLen)
protected static final void lengthToByte(byte[] arr, int off, int len)
protected static final int byteToLength(byte[] arr, int off)
protected static final void shortToByte(byte[] arr, int off, int val)
protected static final int byteToShort(byte[] arr, int off)
protected static final void intToByte(byte[] arr, int off, int val)
protected static final int byteToInt(byte[] arr, int off)
protected static final void longToByte(byte[] arr, int off, long val)
protected static final long byteToLong(byte[] arr, int off)
public final boolean equals(java.lang.Object o)
equals
in interface MeComparator
o
- Description of the Parameter
public java.lang.String toString()
public abstract boolean isValidType(java.lang.Object obj)
obj
- the value object
public abstract int compare(java.lang.Object o1, java.lang.Object o2)
compare
in interface MeComparator
o1
- Description of the Parametero2
- Description of the Parameter
public abstract int compare(byte[] b1, byte[] b2)
b1
- b2
-
public abstract int toByte(byte[] arr, int off, java.lang.Object obj, int len, int dec)
arr
- the destination byte arrayoff
- the offset in byte arrayobj
- the value object (see types above)len
- Description of the Parameter
java.lang.IllegalArgumentException
- if Object type is unsufficentpublic abstract java.lang.Object toValue(byte[] arr, int off)
arr
- Description of the Parameteroff
- Description of the Parameter
public abstract int toByteLen(int len, int dec)
len
- the len of value object
public abstract boolean contains(byte[] b, java.lang.Object o)
public abstract boolean startWith(byte[] b, java.lang.Object o)
public abstract java.lang.Object getDefaultValue(int len, int dec)
public java.lang.Object cloneMutable(java.lang.Object o)
o
-
public boolean equals(byte[] b, java.lang.Object o)
public boolean notEqual(byte[] b, java.lang.Object o)
public boolean greaterThan(byte[] b, java.lang.Object o)
public boolean lowerThan(byte[] b, java.lang.Object o)
protected final int compare(long i1, long i2)
protected final int compare(java.util.Date d1, java.util.Date d2)
public static AttributeType forInstanceId(int id)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |