JHotDraw 6.0b1

org.jhotdraw.util
Class StorableInput

java.lang.Object
  extended by org.jhotdraw.util.StorableInput

public class StorableInput
extends java.lang.Object

An input stream that can be used to resurrect Storable objects. StorableInput preserves the object identity of the stored objects.

See Also:
Storable, StorableOutput

Constructor Summary
StorableInput(java.io.InputStream stream)
          Initializes a Storable input with the given input stream.
 
Method Summary
 boolean readBoolean()
          Reads a boolean from the input stream.
 java.awt.Color readColor()
          Reads a color from the input stream.
 double readDouble()
          Reads a double from the input stream.
 int readInt()
          Reads an int from the input stream.
 long readLong()
          Reads an int from the input stream.
 Storable readStorable()
          Reads and resurrects a Storable object from the input stream.
 java.lang.String readString()
          Reads a string from the input stream.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StorableInput

public StorableInput(java.io.InputStream stream)
Initializes a Storable input with the given input stream.

Method Detail

readStorable

public Storable readStorable()
                      throws java.io.IOException
Reads and resurrects a Storable object from the input stream.

Throws:
java.io.IOException

readString

public java.lang.String readString()
                            throws java.io.IOException
Reads a string from the input stream.

Throws:
java.io.IOException

readInt

public int readInt()
            throws java.io.IOException
Reads an int from the input stream.

Throws:
java.io.IOException

readLong

public long readLong()
              throws java.io.IOException
Reads an int from the input stream.

Throws:
java.io.IOException

readColor

public java.awt.Color readColor()
                         throws java.io.IOException
Reads a color from the input stream.

Throws:
java.io.IOException

readDouble

public double readDouble()
                  throws java.io.IOException
Reads a double from the input stream.

Throws:
java.io.IOException

readBoolean

public boolean readBoolean()
                    throws java.io.IOException
Reads a boolean from the input stream.

Throws:
java.io.IOException

JHotDraw 6.0b1