java.io
Interface ObjectStreamConstants

All Known Implementing Classes:
ObjectInputStream, ObjectOutputStream

public interface ObjectStreamConstants

Constants written into the Object Serialization Stream.

Since:
JDK 1.1

Field Summary
static int baseWireHandle
          Suppressed.
          First wire handle to be assigned.
static int PROTOCOL_VERSION_1
          Suppressed.
          A Stream Protocol Version.
static int PROTOCOL_VERSION_2
          Suppressed.
          A Stream Protocol Version.
static byte SC_BLOCK_DATA
          Suppressed.
          Bit mask for ObjectStreamClass flag.
static byte SC_ENUM
          Suppressed.
          Bit mask for ObjectStreamClass flag.
static byte SC_EXTERNALIZABLE
          Suppressed.
          Bit mask for ObjectStreamClass flag.
static byte SC_SERIALIZABLE
          Suppressed.
          Bit mask for ObjectStreamClass flag.
static byte SC_WRITE_METHOD
          Suppressed.
          Bit mask for ObjectStreamClass flag.
static short STREAM_MAGIC
          Suppressed.
          Magic number that is written to the stream header.
static short STREAM_VERSION
          Suppressed.
          Version number that is written to the stream header.
static SerializablePermission SUBCLASS_IMPLEMENTATION_PERMISSION
          Suppressed.
          Enable overriding of readObject and writeObject.
static SerializablePermission SUBSTITUTION_PERMISSION
          Suppressed.
          Enable substitution of one object for another during serialization/deserialization.
static byte TC_ARRAY
          Suppressed.
          new Array.
static byte TC_BASE
          Suppressed.
          First tag value.
static byte TC_BLOCKDATA
          Suppressed.
          Block of optional data.
static byte TC_BLOCKDATALONG
          Suppressed.
          long Block data.
static byte TC_CLASS
          Suppressed.
          Reference to Class.
static byte TC_CLASSDESC
          Suppressed.
          new Class Descriptor.
static byte TC_ENDBLOCKDATA
          Suppressed.
          End of optional block data blocks for an object.
static byte TC_ENUM
          Suppressed.
          new Enum constant.
static byte TC_EXCEPTION
          Suppressed.
          Exception during write.
static byte TC_LONGSTRING
          Suppressed.
          Long string.
static byte TC_MAX
          Suppressed.
          Last tag value.
static byte TC_NULL
          Suppressed.
          Null object reference.
static byte TC_OBJECT
          Suppressed.
          new Object.
static byte TC_PROXYCLASSDESC
          Suppressed.
          new Proxy Class Descriptor.
static byte TC_REFERENCE
          Suppressed.
          Reference to an object already written into the stream.
static byte TC_RESET
          Suppressed.
          Reset stream context.
static byte TC_STRING
          Suppressed.
          new String.
 

Field Detail

STREAM_MAGIC

static final short STREAM_MAGIC
Suppressed. default deny

Magic number that is written to the stream header.

See Also:
Constant Field Values

STREAM_VERSION

static final short STREAM_VERSION
Suppressed. default deny

Version number that is written to the stream header.

See Also:
Constant Field Values

TC_BASE

static final byte TC_BASE
Suppressed. default deny

First tag value.

See Also:
Constant Field Values

TC_NULL

static final byte TC_NULL
Suppressed. default deny

Null object reference.

See Also:
Constant Field Values

TC_REFERENCE

static final byte TC_REFERENCE
Suppressed. default deny

Reference to an object already written into the stream.

See Also:
Constant Field Values

TC_CLASSDESC

static final byte TC_CLASSDESC
Suppressed. default deny

new Class Descriptor.

See Also:
Constant Field Values

TC_OBJECT

static final byte TC_OBJECT
Suppressed. default deny

new Object.

See Also:
Constant Field Values

TC_STRING

static final byte TC_STRING
Suppressed. default deny

new String.

See Also:
Constant Field Values

TC_ARRAY

static final byte TC_ARRAY
Suppressed. default deny

new Array.

See Also:
Constant Field Values

TC_CLASS

static final byte TC_CLASS
Suppressed. default deny

Reference to Class.

See Also:
Constant Field Values

TC_BLOCKDATA

static final byte TC_BLOCKDATA
Suppressed. default deny

Block of optional data. Byte following tag indicates number of bytes in this block data.

See Also:
Constant Field Values

TC_ENDBLOCKDATA

static final byte TC_ENDBLOCKDATA
Suppressed. default deny

End of optional block data blocks for an object.

See Also:
Constant Field Values

TC_RESET

static final byte TC_RESET
Suppressed. default deny

Reset stream context. All handles written into stream are reset.

See Also:
Constant Field Values

TC_BLOCKDATALONG

static final byte TC_BLOCKDATALONG
Suppressed. default deny

long Block data. The long following the tag indicates the number of bytes in this block data.

See Also:
Constant Field Values

TC_EXCEPTION

static final byte TC_EXCEPTION
Suppressed. default deny

Exception during write.

See Also:
Constant Field Values

TC_LONGSTRING

static final byte TC_LONGSTRING
Suppressed. default deny

Long string.

See Also:
Constant Field Values

TC_PROXYCLASSDESC

static final byte TC_PROXYCLASSDESC
Suppressed. default deny

new Proxy Class Descriptor.

See Also:
Constant Field Values

TC_ENUM

static final byte TC_ENUM
Suppressed. default deny

new Enum constant.

Since:
1.5
See Also:
Constant Field Values

TC_MAX

static final byte TC_MAX
Suppressed. default deny

Last tag value.

See Also:
Constant Field Values

baseWireHandle

static final int baseWireHandle
Suppressed. default deny

First wire handle to be assigned.

See Also:
Constant Field Values

SC_WRITE_METHOD

static final byte SC_WRITE_METHOD
Suppressed. default deny

Bit mask for ObjectStreamClass flag. Indicates a Serializable class defines its own writeObject method.

See Also:
Constant Field Values

SC_BLOCK_DATA

static final byte SC_BLOCK_DATA
Suppressed. default deny

Bit mask for ObjectStreamClass flag. Indicates Externalizable data written in Block Data mode. Added for PROTOCOL_VERSION_2.

Since:
1.2
See Also:
PROTOCOL_VERSION_2, Constant Field Values

SC_SERIALIZABLE

static final byte SC_SERIALIZABLE
Suppressed. default deny

Bit mask for ObjectStreamClass flag. Indicates class is Serializable.

See Also:
Constant Field Values

SC_EXTERNALIZABLE

static final byte SC_EXTERNALIZABLE
Suppressed. default deny

Bit mask for ObjectStreamClass flag. Indicates class is Externalizable.

See Also:
Constant Field Values

SC_ENUM

static final byte SC_ENUM
Suppressed. default deny

Bit mask for ObjectStreamClass flag. Indicates class is an enum type.

Since:
1.5
See Also:
Constant Field Values

SUBSTITUTION_PERMISSION

static final SerializablePermission SUBSTITUTION_PERMISSION
Suppressed. default deny

Enable substitution of one object for another during serialization/deserialization.

Since:
1.2
See Also:
ObjectOutputStream.enableReplaceObject(boolean), ObjectInputStream.enableResolveObject(boolean)

SUBCLASS_IMPLEMENTATION_PERMISSION

static final SerializablePermission SUBCLASS_IMPLEMENTATION_PERMISSION
Suppressed. default deny

Enable overriding of readObject and writeObject.

Since:
1.2
See Also:
ObjectOutputStream.writeObjectOverride(Object), ObjectInputStream.readObjectOverride()

PROTOCOL_VERSION_1

static final int PROTOCOL_VERSION_1
Suppressed. default deny

A Stream Protocol Version.

All externalizable data is written in JDK 1.1 external data format after calling this method. This version is needed to write streams containing Externalizable data that can be read by pre-JDK 1.1.6 JVMs.

Since:
1.2
See Also:
ObjectOutputStream.useProtocolVersion(int), Constant Field Values

PROTOCOL_VERSION_2

static final int PROTOCOL_VERSION_2
Suppressed. default deny

A Stream Protocol Version.

This protocol is written by JVM 1.2. Externalizable data is written in block data mode and is terminated with TC_ENDBLOCKDATA. Externalizable classdescriptor flags has SC_BLOCK_DATA enabled. JVM 1.1.6 and greater can read this format change. Enables writing a nonSerializable class descriptor into the stream. The serialVersionUID of a nonSerializable class is set to 0L.

Since:
1.2
See Also:
ObjectOutputStream.useProtocolVersion(int), SC_BLOCK_DATA, Constant Field Values