aerospike / aerospike-client-java

Aerospike Java Client Library
Other
236 stars 212 forks source link

Value class does not support char and byte types #75

Closed Aloren closed 7 years ago

Aloren commented 7 years ago

There are multiple implementations of Value class, e.g.: DoubleValue, BooleanValue etc. If I want to store primitive of type byte or char -- BlobValue is used for storing. Why there is no ByteValue?

BrianNichols commented 7 years ago

This is a server question. The client doesn't support a byte value, because the server doesn't support a byte value.

BooleanValue is not supported by the server either, but it was added on the client to provide an boolean abstraction. BooleanValue instances send/receive integers to/from the server.

Aloren commented 7 years ago

Byte can be saved as integer or as long as I understood. So why not to add ByteValue as it was done for boolean?

BrianNichols commented 7 years ago

We will look into adding ByteValue in the next release.

BrianNichols commented 7 years ago

Java client 4.0.0 adds ByteValue.

http://www.aerospike.com/download/client/java/4.0.0/