|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sleepycat.persist.impl.Format
com.sleepycat.persist.impl.SimpleFormat
public abstract class SimpleFormat
Format for simple types, including primitives. Additional methods are included to optimize the handling of primitives. Other classes such as PrimitiveArrayFormat and ReflectAccessor take advantage of these methods.
Nested Class Summary | |
---|---|
static class |
SimpleFormat.FBigInt
|
static class |
SimpleFormat.FBool
|
static class |
SimpleFormat.FByte
|
static class |
SimpleFormat.FChar
|
static class |
SimpleFormat.FDate
|
static class |
SimpleFormat.FDouble
|
static class |
SimpleFormat.FFloat
|
static class |
SimpleFormat.FInt
|
static class |
SimpleFormat.FLong
|
static class |
SimpleFormat.FShort
|
static class |
SimpleFormat.FString
|
Method Summary | |
---|---|
boolean |
isPrimitive()
Returns whether this type is a Java primitive: char, byte, short, int, long, float or double. |
boolean |
isSimple()
Returns whether this is a simple type: primitive, primitive wrapper, BigInteger, String or Date. |
java.lang.Object |
readObject(java.lang.Object o,
EntityInput input,
boolean rawAccess)
Called after newInstance() to read the rest of the data bytes and fill in the object contents. |
Methods inherited from class com.sleepycat.persist.impl.Format |
---|
getClassName, getComponentType, getDimensions, getEnumConstants, getFields, getPreviousVersion, getSuperType, getVersion, initializeReader, isArray, isEnum, newInstance, readPriKey, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Method Detail |
---|
public boolean isSimple()
RawType
If true is returned, RawType.isPrimitive()
can be called for more
information, and a raw value of this type is represented as a simple
type object (not as a RawObject
).
If false is returned, this is a complex type, an array type (see
RawType.isArray()
), or an enum type, and a raw value of this type is
represented as a RawObject
.
isSimple
in interface RawType
isSimple
in class Format
public boolean isPrimitive()
RawType
If true is returned, this is also a simple type. In other words, primitive types are a subset of simple types.
If true is returned, a raw value of this type is represented as a
non-null instance of the primitive type's wrapper class. For example,
an int
raw value is represented as an
Integer
.
isPrimitive
in interface RawType
isPrimitive
in class Format
public java.lang.Object readObject(java.lang.Object o, EntityInput input, boolean rawAccess)
Format
readObject
in class Format
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |