Package org.apache.cassandra.db.marshal
Class NumberType.NumberArgumentDeserializer<M extends org.apache.commons.lang3.mutable.Mutable<Number>>
java.lang.Object
org.apache.cassandra.db.marshal.NumberType.NumberArgumentDeserializer<M>
- Type Parameters:
M- The Mutable wrapper type
- All Implemented Interfaces:
ArgumentDeserializer
- Enclosing class:
- NumberType<T extends Number>
protected abstract static class NumberType.NumberArgumentDeserializer<M extends org.apache.commons.lang3.mutable.Mutable<Number>>
extends Object
implements ArgumentDeserializer
Base class for numeric type
ArgumentDeserializer.
This class uses and returns a mutable wrapper instead of the Java immutable primitive wrapper. This wrapper is being reused between each call to minimize the amount of objects instantiated.
-
Field Summary
FieldsFields inherited from interface org.apache.cassandra.cql3.functions.ArgumentDeserializer
NOOP_DESERIALIZER -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondeserialize(ProtocolVersion protocolVersion, ByteBuffer buffer) Deserializes the specified function argument.protected abstract voidsetMutableValue(M mutable, ByteBuffer buffer) Sets the value of the mutable.
-
Field Details
-
wrapper
-
-
Constructor Details
-
NumberArgumentDeserializer
-
-
Method Details
-
deserialize
Description copied from interface:ArgumentDeserializerDeserializes the specified function argument.- Specified by:
deserializein interfaceArgumentDeserializer- Parameters:
protocolVersion- the protocol versionbuffer- the serialized argument- Returns:
- the deserialized argument
-
setMutableValue
Sets the value of the mutable.- Parameters:
buffer- the serialized value.
-