jsdsi.sexp
Class SexpInputStream

java.lang.Object
  extended byjava.io.InputStream
      extended byjava.io.FilterInputStream
          extended byjsdsi.sexp.SexpInputStream
All Implemented Interfaces:
SexpInput

public class SexpInputStream
extends java.io.FilterInputStream
implements SexpInput

Reads serialized S-expressions from an underlying stream. Supports the canonical, transport, and readable S-expression encodings.

Version:
$Revision: 1.1.6.1 $ $Date: 2005/11/08 03:12:52 $
Author:
Sameer Ajmani
See Also:
SexpOutputStream

Field Summary
 
Fields inherited from class java.io.FilterInputStream
in
 
Constructor Summary
SexpInputStream(java.io.InputStream is)
          Creates a new SexpInputStream that reads from the given stream.
 
Method Summary
 Sexp readSexp()
          Reads the next S-expression from the stream.
 
Methods inherited from class java.io.FilterInputStream
available, close, mark, markSupported, read, read, read, reset, skip
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SexpInputStream

public SexpInputStream(java.io.InputStream is)
Creates a new SexpInputStream that reads from the given stream.

Method Detail

readSexp

public Sexp readSexp()
              throws SexpException,
                     java.io.IOException
Reads the next S-expression from the stream.

Specified by:
readSexp in interface SexpInput
Returns:
the decoded S-expression.
Throws:
java.io.EOFException - if the stream is empty.
SexpException - if there is a decoding error.
java.io.IOException - if there is an IO error.


Copyright © 2002-2006 JSDSI. All Rights Reserved.