public class DefaultBinaryContext extends java.lang.Object implements BinaryContext
| Constructor and Description |
|---|
DefaultBinaryContext() |
DefaultBinaryContext(java.nio.charset.Charset charset,
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
beginReadStructure(IoBuffer buffer,
boolean allowNull) |
java.lang.Integer |
beginReadStructureList(IoBuffer buffer,
boolean allowNull) |
void |
beginWriteStructure(IoBuffer buffer,
byte fieldNumber,
boolean isNull) |
void |
beginWriteStructureList(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<?> values) |
java.lang.Boolean |
decodeBoolean(IoBuffer buffer) |
java.util.List<java.lang.Boolean> |
decodeBooleanList(IoBuffer buffer) |
java.util.Set<java.lang.Boolean> |
decodeBooleanSet(IoBuffer buffer) |
java.lang.Double |
decodeDouble(IoBuffer buffer) |
java.util.List<java.lang.Double> |
decodeDoubleList(IoBuffer buffer) |
java.util.Set<java.lang.Double> |
decodeDoubleSet(IoBuffer buffer) |
<E extends java.lang.Enum<E>> |
decodeEnum(IoBuffer buffer,
java.lang.Class<E> enumClazz) |
<E extends java.lang.Enum<E>> |
decodeEnumList(IoBuffer buffer,
java.lang.Class<E> enumClazz) |
<E extends java.lang.Enum<E>> |
decodeEnumSet(IoBuffer buffer,
java.lang.Class<E> enumClazz) |
java.lang.Integer |
decodeInt(IoBuffer buffer) |
java.util.List<java.lang.Integer> |
decodeIntList(IoBuffer buffer) |
java.util.Set<java.lang.Integer> |
decodeIntSet(IoBuffer buffer) |
java.lang.Long |
decodeLong(IoBuffer buffer) |
java.util.List<java.lang.Long> |
decodeLongList(IoBuffer buffer) |
java.util.Set<java.lang.Long> |
decodeLongSet(IoBuffer buffer) |
boolean |
decodePrimitiveBoolean(IoBuffer buffer) |
double |
decodePrimitiveDouble(IoBuffer buffer) |
int |
decodePrimitiveInt(IoBuffer buffer) |
long |
decodePrimitiveLong(IoBuffer buffer) |
java.util.Map<java.lang.String,java.lang.String> |
decodeProperties(IoBuffer buffer) |
java.util.List<java.util.Map<java.lang.String,java.lang.String>> |
decodePropertiesList(IoBuffer buffer) |
java.util.Set<java.util.Map<java.lang.String,java.lang.String>> |
decodePropertiesSet(IoBuffer buffer) |
java.lang.String |
decodeString(IoBuffer buffer) |
java.util.List<java.lang.String> |
decodeStringList(IoBuffer buffer) |
java.util.Set<java.lang.String> |
decodeStringSet(IoBuffer buffer) |
Variant |
decodeVariant(IoBuffer buffer) |
java.util.List<Variant> |
decodeVariantList(IoBuffer buffer) |
java.util.Map<java.lang.String,Variant> |
decodeVariantMap(IoBuffer buffer) |
java.util.List<java.util.Map<java.lang.String,Variant>> |
decodeVariantMapList(IoBuffer buffer) |
java.util.Set<java.util.Map<java.lang.String,Variant>> |
decodeVariantMapSet(IoBuffer buffer) |
java.util.Set<Variant> |
decodeVariantSet(IoBuffer buffer) |
void |
encodeBoolean(IoBuffer buffer,
byte fieldNumber,
java.lang.Boolean data) |
void |
encodeBooleanCollection(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<java.lang.Boolean> data) |
void |
encodeDouble(IoBuffer buffer,
byte fieldNumber,
java.lang.Double data) |
void |
encodeDoubleCollection(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<java.lang.Double> data) |
<E extends java.lang.Enum<E>> |
encodeEnum(IoBuffer buffer,
byte fieldNumber,
E value) |
<E extends java.lang.Enum<E>> |
encodeEnumList(IoBuffer buffer,
byte fieldNumber,
java.util.List<E> data) |
<E extends java.lang.Enum<E>> |
encodeEnumSet(IoBuffer buffer,
byte fieldNumber,
java.util.Set<E> data) |
void |
encodeInt(IoBuffer buffer,
byte fieldNumber,
java.lang.Integer data) |
void |
encodeIntCollection(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<java.lang.Integer> data) |
void |
encodeLong(IoBuffer buffer,
byte fieldNumber,
java.lang.Long data) |
void |
encodeLongCollection(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<java.lang.Long> data) |
void |
encodePrimitiveBoolean(IoBuffer buffer,
byte fieldNumber,
boolean data) |
void |
encodePrimitiveDouble(IoBuffer buffer,
byte fieldNumber,
double data) |
void |
encodePrimitiveInt(IoBuffer buffer,
byte fieldNumber,
int data) |
void |
encodePrimitiveLong(IoBuffer buffer,
byte fieldNumber,
long data) |
void |
encodeProperties(IoBuffer buffer,
byte fieldNumber,
java.util.Map<java.lang.String,java.lang.String> data) |
void |
encodePropertiesCollection(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<java.util.Map<java.lang.String,java.lang.String>> data) |
void |
encodeString(IoBuffer buffer,
byte fieldNumber,
java.lang.String data) |
void |
encodeStringCollection(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<java.lang.String> data) |
void |
encodeVariant(IoBuffer buffer,
byte fieldNumber,
Variant data) |
void |
encodeVariantCollection(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<Variant> data) |
void |
encodeVariantMap(IoBuffer buffer,
byte fieldNumber,
java.util.Map<java.lang.String,Variant> data) |
void |
encodeVariantMapCollection(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<java.util.Map<java.lang.String,Variant>> data) |
java.lang.String |
getProtocolIdPart() |
protected <E extends java.lang.Enum<E>> |
inlineDecodeEnum(IoBuffer data,
java.lang.Class<E> enumClazz) |
protected java.util.Map<java.lang.String,java.lang.String> |
inlineDecodeProperties(IoBuffer buffer) |
protected java.util.Map<java.lang.String,Variant> |
inlineDecodeVariantMap(IoBuffer buffer) |
protected void |
inlineEncodeEnum(IoBuffer data,
java.lang.Enum<?> value) |
protected void |
inlineEncodeProperties(IoBuffer buffer,
java.util.Map<java.lang.String,java.lang.String> data) |
protected void |
inlineEncodeVariantMap(IoBuffer buffer,
java.util.Map<java.lang.String,Variant> data) |
public DefaultBinaryContext(java.nio.charset.Charset charset,
stringInterner)
public DefaultBinaryContext()
public java.lang.String getProtocolIdPart()
getProtocolIdPart in interface BinaryContextpublic void encodeString(IoBuffer buffer,
byte fieldNumber,
java.lang.String data)
throws java.lang.Exception
encodeString in interface BinaryContextjava.lang.Exceptionpublic java.lang.String decodeString(IoBuffer buffer)
throws java.lang.Exception
decodeString in interface BinaryContextjava.lang.Exceptionpublic void encodeStringCollection(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<java.lang.String> data)
throws java.lang.Exception
encodeStringCollection in interface BinaryContextjava.lang.Exceptionpublic java.util.List<java.lang.String> decodeStringList(IoBuffer buffer)
throws java.lang.Exception
decodeStringList in interface BinaryContextjava.lang.Exceptionpublic java.util.Set<java.lang.String> decodeStringSet(IoBuffer buffer)
throws java.lang.Exception
decodeStringSet in interface BinaryContextjava.lang.Exceptionpublic void encodeLong(IoBuffer buffer,
byte fieldNumber,
java.lang.Long data)
throws java.lang.Exception
encodeLong in interface BinaryContextjava.lang.Exceptionpublic java.lang.Long decodeLong(IoBuffer buffer)
throws java.lang.Exception
decodeLong in interface BinaryContextjava.lang.Exceptionpublic void encodePrimitiveLong(IoBuffer buffer,
byte fieldNumber,
long data)
throws java.lang.Exception
encodePrimitiveLong in interface BinaryContextjava.lang.Exceptionpublic long decodePrimitiveLong(IoBuffer buffer)
throws java.lang.Exception
decodePrimitiveLong in interface BinaryContextjava.lang.Exceptionpublic void encodeLongCollection(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<java.lang.Long> data)
throws java.lang.Exception
encodeLongCollection in interface BinaryContextjava.lang.Exceptionpublic java.util.List<java.lang.Long> decodeLongList(IoBuffer buffer)
throws java.lang.Exception
decodeLongList in interface BinaryContextjava.lang.Exceptionpublic java.util.Set<java.lang.Long> decodeLongSet(IoBuffer buffer)
throws java.lang.Exception
decodeLongSet in interface BinaryContextjava.lang.Exceptionpublic void encodeInt(IoBuffer buffer,
byte fieldNumber,
java.lang.Integer data)
throws java.lang.Exception
encodeInt in interface BinaryContextjava.lang.Exceptionpublic java.lang.Integer decodeInt(IoBuffer buffer)
throws java.lang.Exception
decodeInt in interface BinaryContextjava.lang.Exceptionpublic void encodePrimitiveInt(IoBuffer buffer,
byte fieldNumber,
int data)
throws java.lang.Exception
encodePrimitiveInt in interface BinaryContextjava.lang.Exceptionpublic int decodePrimitiveInt(IoBuffer buffer)
throws java.lang.Exception
decodePrimitiveInt in interface BinaryContextjava.lang.Exceptionpublic void encodeIntCollection(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<java.lang.Integer> data)
throws java.lang.Exception
encodeIntCollection in interface BinaryContextjava.lang.Exceptionpublic java.util.List<java.lang.Integer> decodeIntList(IoBuffer buffer)
throws java.lang.Exception
decodeIntList in interface BinaryContextjava.lang.Exceptionpublic java.util.Set<java.lang.Integer> decodeIntSet(IoBuffer buffer)
throws java.lang.Exception
decodeIntSet in interface BinaryContextjava.lang.Exceptionpublic void encodeBoolean(IoBuffer buffer,
byte fieldNumber,
java.lang.Boolean data)
throws java.lang.Exception
encodeBoolean in interface BinaryContextjava.lang.Exceptionpublic java.lang.Boolean decodeBoolean(IoBuffer buffer)
throws java.lang.Exception
decodeBoolean in interface BinaryContextjava.lang.Exceptionpublic void encodePrimitiveBoolean(IoBuffer buffer,
byte fieldNumber,
boolean data)
throws java.lang.Exception
encodePrimitiveBoolean in interface BinaryContextjava.lang.Exceptionpublic boolean decodePrimitiveBoolean(IoBuffer buffer)
throws java.lang.Exception
decodePrimitiveBoolean in interface BinaryContextjava.lang.Exceptionpublic void encodeBooleanCollection(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<java.lang.Boolean> data)
throws java.lang.Exception
encodeBooleanCollection in interface BinaryContextjava.lang.Exceptionpublic java.util.List<java.lang.Boolean> decodeBooleanList(IoBuffer buffer)
throws java.lang.Exception
decodeBooleanList in interface BinaryContextjava.lang.Exceptionpublic java.util.Set<java.lang.Boolean> decodeBooleanSet(IoBuffer buffer)
throws java.lang.Exception
decodeBooleanSet in interface BinaryContextjava.lang.Exceptionpublic void encodeDouble(IoBuffer buffer,
byte fieldNumber,
java.lang.Double data)
throws java.lang.Exception
encodeDouble in interface BinaryContextjava.lang.Exceptionpublic java.lang.Double decodeDouble(IoBuffer buffer)
throws java.lang.Exception
decodeDouble in interface BinaryContextjava.lang.Exceptionpublic void encodePrimitiveDouble(IoBuffer buffer,
byte fieldNumber,
double data)
throws java.lang.Exception
encodePrimitiveDouble in interface BinaryContextjava.lang.Exceptionpublic double decodePrimitiveDouble(IoBuffer buffer)
throws java.lang.Exception
decodePrimitiveDouble in interface BinaryContextjava.lang.Exceptionpublic void encodeDoubleCollection(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<java.lang.Double> data)
throws java.lang.Exception
encodeDoubleCollection in interface BinaryContextjava.lang.Exceptionpublic java.util.List<java.lang.Double> decodeDoubleList(IoBuffer buffer)
throws java.lang.Exception
decodeDoubleList in interface BinaryContextjava.lang.Exceptionpublic java.util.Set<java.lang.Double> decodeDoubleSet(IoBuffer buffer)
throws java.lang.Exception
decodeDoubleSet in interface BinaryContextjava.lang.Exceptionpublic void encodeVariant(IoBuffer buffer,
byte fieldNumber,
Variant data)
throws java.lang.Exception
encodeVariant in interface BinaryContextjava.lang.Exceptionpublic Variant decodeVariant(IoBuffer buffer)
throws java.lang.Exception
decodeVariant in interface BinaryContextjava.lang.Exceptionpublic void encodeVariantCollection(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<Variant> data)
throws java.lang.Exception
encodeVariantCollection in interface BinaryContextjava.lang.Exceptionpublic java.util.List<Variant> decodeVariantList(IoBuffer buffer)
throws java.lang.Exception
decodeVariantList in interface BinaryContextjava.lang.Exceptionpublic java.util.Set<Variant> decodeVariantSet(IoBuffer buffer)
throws java.lang.Exception
decodeVariantSet in interface BinaryContextjava.lang.Exceptionprotected void inlineEncodeVariantMap(IoBuffer buffer,
java.util.Map<java.lang.String,Variant> data)
throws java.lang.Exception
java.lang.Exceptionprotected java.util.Map<java.lang.String,Variant> inlineDecodeVariantMap(IoBuffer buffer)
throws java.lang.Exception
java.lang.Exceptionpublic void encodeVariantMap(IoBuffer buffer,
byte fieldNumber,
java.util.Map<java.lang.String,Variant> data)
throws java.lang.Exception
encodeVariantMap in interface BinaryContextjava.lang.Exceptionpublic java.util.Map<java.lang.String,Variant> decodeVariantMap(IoBuffer buffer)
throws java.lang.Exception
decodeVariantMap in interface BinaryContextjava.lang.Exceptionpublic void encodeVariantMapCollection(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<java.util.Map<java.lang.String,Variant>> data)
throws java.lang.Exception
encodeVariantMapCollection in interface BinaryContextjava.lang.Exceptionpublic java.util.List<java.util.Map<java.lang.String,Variant>> decodeVariantMapList(IoBuffer buffer)
throws java.lang.Exception
decodeVariantMapList in interface BinaryContextjava.lang.Exceptionpublic java.util.Set<java.util.Map<java.lang.String,Variant>> decodeVariantMapSet(IoBuffer buffer)
throws java.lang.Exception
decodeVariantMapSet in interface BinaryContextjava.lang.Exceptionprotected void inlineEncodeProperties(IoBuffer buffer,
java.util.Map<java.lang.String,java.lang.String> data)
throws java.lang.Exception
java.lang.Exceptionprotected java.util.Map<java.lang.String,java.lang.String> inlineDecodeProperties(IoBuffer buffer)
throws java.lang.Exception
java.lang.Exceptionpublic void encodeProperties(IoBuffer buffer,
byte fieldNumber,
java.util.Map<java.lang.String,java.lang.String> data)
throws java.lang.Exception
encodeProperties in interface BinaryContextjava.lang.Exceptionpublic java.util.Map<java.lang.String,java.lang.String> decodeProperties(IoBuffer buffer)
throws java.lang.Exception
decodeProperties in interface BinaryContextjava.lang.Exceptionpublic void encodePropertiesCollection(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<java.util.Map<java.lang.String,java.lang.String>> data)
throws java.lang.Exception
encodePropertiesCollection in interface BinaryContextjava.lang.Exceptionpublic java.util.List<java.util.Map<java.lang.String,java.lang.String>> decodePropertiesList(IoBuffer buffer)
throws java.lang.Exception
decodePropertiesList in interface BinaryContextjava.lang.Exceptionpublic java.util.Set<java.util.Map<java.lang.String,java.lang.String>> decodePropertiesSet(IoBuffer buffer)
throws java.lang.Exception
decodePropertiesSet in interface BinaryContextjava.lang.Exceptionprotected void inlineEncodeEnum(IoBuffer data,
java.lang.Enum<?> value)
protected <E extends java.lang.Enum<E>> E inlineDecodeEnum(IoBuffer data,
java.lang.Class<E> enumClazz)
public <E extends java.lang.Enum<E>> void encodeEnum(IoBuffer buffer,
byte fieldNumber,
E value)
throws java.lang.Exception
encodeEnum in interface BinaryContextjava.lang.Exceptionpublic <E extends java.lang.Enum<E>> E decodeEnum(IoBuffer buffer,
java.lang.Class<E> enumClazz)
throws java.lang.Exception
decodeEnum in interface BinaryContextjava.lang.Exceptionpublic <E extends java.lang.Enum<E>> void encodeEnumList(IoBuffer buffer,
byte fieldNumber,
java.util.List<E> data)
throws java.lang.Exception
encodeEnumList in interface BinaryContextjava.lang.Exceptionpublic <E extends java.lang.Enum<E>> java.util.List<E> decodeEnumList(IoBuffer buffer,
java.lang.Class<E> enumClazz)
throws java.lang.Exception
decodeEnumList in interface BinaryContextjava.lang.Exceptionpublic <E extends java.lang.Enum<E>> void encodeEnumSet(IoBuffer buffer,
byte fieldNumber,
java.util.Set<E> data)
throws java.lang.Exception
encodeEnumSet in interface BinaryContextjava.lang.Exceptionpublic <E extends java.lang.Enum<E>> java.util.Set<E> decodeEnumSet(IoBuffer buffer,
java.lang.Class<E> enumClazz)
throws java.lang.Exception
decodeEnumSet in interface BinaryContextjava.lang.Exceptionpublic boolean beginReadStructure(IoBuffer buffer,
boolean allowNull)
throws java.lang.Exception
beginReadStructure in interface BinaryContextjava.lang.Exceptionpublic void beginWriteStructure(IoBuffer buffer,
byte fieldNumber,
boolean isNull)
throws java.lang.Exception
beginWriteStructure in interface BinaryContextjava.lang.Exceptionpublic java.lang.Integer beginReadStructureList(IoBuffer buffer,
boolean allowNull)
throws java.lang.Exception
beginReadStructureList in interface BinaryContextjava.lang.Exceptionpublic void beginWriteStructureList(IoBuffer buffer,
byte fieldNumber,
java.util.Collection<?> values)
throws java.lang.Exception
beginWriteStructureList in interface BinaryContextjava.lang.Exception
Copyright (c) IBH SYSTEMS GmbH and others 2010, 2013.
All rights reserved. This program and the accompanying materials
are made available under the terms of the
Eclipse Public License v1.0