if (version.ordinal() > 0)
if (version.ordinal() > 0)
/** * @since 2.7 */ public EObjectOutputStream(OutputStream outputStream, Map<?, ?> options, Version version, int style) throws IOException { this.outputStream = outputStream; this.options = options; this.version = version; this.style = style; int bufferCapacity = getInternalBufferCapacity(options); if (bufferCapacity > 1) { bytes = new byte[bufferCapacity]; } writeSignature(); writeVersion(); if (version.ordinal() > 0) { writeStyle(); } if ((style & STYLE_DATA_CONVERTER) != 0) { segmentedStringToIDMap = new HashMap<String, Integer>(); segmentToIDMap = new HashMap<String, Integer>(INTRINSIC_STRING_TO_ID_MAP); } }
/** * @since 2.7 */ public EObjectOutputStream(OutputStream outputStream, Map<?, ?> options, Version version, int style) throws IOException { this.outputStream = outputStream; this.options = options; this.version = version; this.style = style; int bufferCapacity = getInternalBufferCapacity(options); if (bufferCapacity > 1) { bytes = new byte[bufferCapacity]; } writeSignature(); writeVersion(); if (version.ordinal() > 0) { writeStyle(); } if ((style & STYLE_DATA_CONVERTER) != 0) { segmentedStringToIDMap = new HashMap<String, Integer>(); segmentToIDMap = new HashMap<String, Integer>(INTRINSIC_STRING_TO_ID_MAP); } }
protected void writeVersion() throws IOException { writeByte(version.ordinal()); }
public EObjectOutputStream(OutputStream outputStream, Map<?, ?> options, Version version) throws IOException { this(outputStream, options, version, version.ordinal() > 0 ? getStyle(options) : STYLE_BINARY_FLOATING_POINT); }
protected void readVersion() throws IOException { version = Version.values()[readByte()]; }
protected void readVersion() throws IOException { version = Version.values()[readByte()]; }
protected void writeVersion() throws IOException { writeByte(version.ordinal()); }
public EObjectOutputStream(OutputStream outputStream, Map<?, ?> options, Version version) throws IOException { this(outputStream, options, version, version.ordinal() > 0 ? getStyle(options) : STYLE_BINARY_FLOATING_POINT); }