|
Oracle NoSQL Database version 11gR2.2.0.26 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
T
- is the type of the deserialized object that is passed to toValue
and returned by toObject
. The specific
type depends on the particular binding that is used.public interface ValueBinding<T>
Generic interface for translating between Value
s (stored byte
arrays) and typed objects representing that value. In other words, this
interface is used for serialization and deserialization of Value
s.
A built-in AvroBinding
, which is a ValueBinding
subtype, may
be obtained from the AvroCatalog
. Or, the ValueBinding
interface may be implemented directly by the application to create custom
bindings, when the Avro data format is not used.
WARNING: We strongly recommend using an AvroBinding
. NoSQL
DB will leverage Avro in the future to provide additional features and
capabilities.
AvroBinding
,
AvroCatalog
Method Summary | |
---|---|
T |
toObject(Value value)
After doing a read operation using a KVStore method, the user
calls toObject with the Value obtained from the read
operation. |
Value |
toValue(T object)
Before doing a write operation, the user calls toValue passing
an object she wishes to store. |
Method Detail |
---|
T toObject(Value value) throws RuntimeException
KVStore
method, the user
calls toObject
with the Value
obtained from the read
operation.
value
- the Value
obtained from a KVStore
read
operation method.
RuntimeException
- if a parameter value is disallowed by the
binding; see AvroBinding
for specific exceptions thrown when
using the Avro format.Value toValue(T object) throws RuntimeException
toValue
passing
an object she wishes to store. The resulting Value
is then
passed to the write operation method in KVStore
.
object
- the object the user wishes to store, or at least
serialize.
RuntimeException
- if a parameter value is disallowed by the
binding; see AvroBinding
for specific exceptions thrown when
using the Avro format.
|
Oracle NoSQL Database version 11gR2.2.0.26 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |