jtge.engine.io
Class XStreamInput

java.lang.Object
  extended byjtge.engine.io.XStreamInput
All Implemented Interfaces:
IInputImp

public class XStreamInput
extends java.lang.Object
implements IInputImp

Implements an input implementation based on the XStream library.

Version:
$Revision: 1.9 $ $Date: 2005/09/10 11:26:47 $
Author:
Mathieu Champlon
See Also:
XStream

Constructor Summary
XStreamInput(java.io.InputStream stream)
          Create an input.
 
Method Summary
 void close()
          Close the input if needed.
 boolean isClosed()
          Check whether the input is closed or not.
 ICommand read()
          Read one command.

This method should block until the reading is done.
The input must be closed when the method returns null.

 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XStreamInput

public XStreamInput(java.io.InputStream stream)
Create an input.

Parameters:
stream - the stream to read data from
Method Detail

read

public final ICommand read()
Read one command.

This method should block until the reading is done.
The input must be closed when the method returns null.

Specified by:
read in interface IInputImp
Returns:
read command or null if the input is closed

close

public final void close()
Close the input if needed.

Specified by:
close in interface IInputImp

isClosed

public final boolean isClosed()
Check whether the input is closed or not.

Specified by:
isClosed in interface IInputImp
Returns:
current close status.


Copyright © 2003-2005 . All Rights Reserved.