Search in sources :

Example 6 with Type

use of com.cinchapi.concourse.thrift.Type in project concourse by cinchapi.

the class TObjectResultDataset method deserializeValue.

@Override
protected TObject deserializeValue(Buffer buffer) {
    Type type = Type.values()[buffer.readByte()];
    int length = buffer.readInt();
    byte[] data = new byte[length];
    buffer.read(data);
    return new TObject(ByteBuffer.wrap(data), type);
}
Also used : Type(com.cinchapi.concourse.thrift.Type) TObject(com.cinchapi.concourse.thrift.TObject)

Aggregations

Type (com.cinchapi.concourse.thrift.Type)6 TObject (com.cinchapi.concourse.thrift.TObject)5 ByteBuffer (java.nio.ByteBuffer)2 FunctionValueSymbol (com.cinchapi.ccl.grammar.FunctionValueSymbol)1 Symbol (com.cinchapi.ccl.grammar.Symbol)1 Function (com.cinchapi.ccl.type.Function)1 IndexFunction (com.cinchapi.ccl.type.function.IndexFunction)1 KeyConditionFunction (com.cinchapi.ccl.type.function.KeyConditionFunction)1 KeyRecordsFunction (com.cinchapi.ccl.type.function.KeyRecordsFunction)1 TemporalFunction (com.cinchapi.ccl.type.function.TemporalFunction)1 Link (com.cinchapi.concourse.Link)1 Tag (com.cinchapi.concourse.Tag)1 Timestamp (com.cinchapi.concourse.Timestamp)1 ComplexTObject (com.cinchapi.concourse.thrift.ComplexTObject)1 Buffer (io.atomix.catalyst.buffer.Buffer)1 HeapBuffer (io.atomix.catalyst.buffer.HeapBuffer)1 Serializable (java.io.Serializable)1 BigDecimal (java.math.BigDecimal)1