public EncodedValue adjust(EncodedValue encodedArray) { final ByteArrayOutputStream baos = new ByteArrayOutputStream(encodedArray.data.length); new EncodedValueTransformer( new ByteOutput() { @Override public void writeByte(int i) { baos.write(i); } } ).transformArray( new EncodedValueReader(encodedArray, EncodedValueReader.ENCODED_ARRAY) ); return new EncodedValue(encodedArray.off, baos.toByteArray()); }
public Annotation adjust(Annotation annotation) { final ByteArrayOutputStream baos = new ByteArrayOutputStream(annotation.encodedAnnotation.data.length); new EncodedValueTransformer( new ByteOutput() { @Override public void writeByte(int i) { baos.write(i); } } ).transformAnnotation(annotation.getReader()); return new Annotation( annotation.off, annotation.visibility, new EncodedValue(annotation.encodedAnnotation.off, baos.toByteArray()) ); }
public Annotation readAnnotation() { int off = data.position(); byte visibility = readByte(); int start = data.position(); new EncodedValueReader(this, EncodedValueReader.ENCODED_ANNOTATION).skipValue(); return new Annotation(off, visibility, new EncodedValue(start, getBytesFrom(start))); }
public EncodedValue readEncodedArray() { int start = data.position(); new EncodedValueReader(this, EncodedValueReader.ENCODED_ARRAY).skipValue(); return new EncodedValue(start, getBytesFrom(start)); }
public EncodedValue adjust(EncodedValue encodedArray) { final ByteArrayOutputStream baos = new ByteArrayOutputStream(encodedArray.data.length); new EncodedValueTransformer( new ByteOutput() { @Override public void writeByte(int i) { baos.write(i); } } ).transformArray( new EncodedValueReader(encodedArray, EncodedValueReader.ENCODED_ARRAY) ); return new EncodedValue(encodedArray.off, baos.toByteArray()); }
public EncodedValue adjust(EncodedValue encodedArray) { final ByteArrayOutputStream baos = new ByteArrayOutputStream(encodedArray.data.length); new EncodedValueTransformer( new ByteOutput() { @Override public void writeByte(int i) { baos.write(i); } } ).transformArray( new EncodedValueReader(encodedArray, EncodedValueReader.ENCODED_ARRAY) ); return new EncodedValue(encodedArray.off, baos.toByteArray()); }
public Annotation adjust(Annotation annotation) { final ByteArrayOutputStream baos = new ByteArrayOutputStream(annotation.encodedAnnotation.data.length); new EncodedValueTransformer( new ByteOutput() { @Override public void writeByte(int i) { baos.write(i); } } ).transformAnnotation(annotation.getReader()); return new Annotation( annotation.off, annotation.visibility, new EncodedValue(annotation.encodedAnnotation.off, baos.toByteArray()) ); }
public Annotation adjust(Annotation annotation) { final ByteArrayOutputStream baos = new ByteArrayOutputStream(annotation.encodedAnnotation.data.length); new EncodedValueTransformer( new ByteOutput() { @Override public void writeByte(int i) { baos.write(i); } } ).transformAnnotation(annotation.getReader()); return new Annotation( annotation.off, annotation.visibility, new EncodedValue(annotation.encodedAnnotation.off, baos.toByteArray()) ); }
public Annotation readAnnotation() { int off = data.position(); byte visibility = readByte(); int start = data.position(); new EncodedValueReader(this, EncodedValueReader.ENCODED_ANNOTATION).skipValue(); return new Annotation(off, visibility, new EncodedValue(start, getBytesFrom(start))); }
public EncodedValue readEncodedArray() { int start = data.position(); new EncodedValueReader(this, EncodedValueReader.ENCODED_ARRAY).skipValue(); return new EncodedValue(start, getBytesFrom(start)); }