package at.gv.egovernment.moa.spss.server.iaik.xml;
import java.io.InputStream;
import iaik.server.modules.xml.BinaryDataObject;
/**
* A BinaryDataObject
encapsulating binary data from a stream.
*
* @author Patrick Peck
* @version $Id$
*/
public class ByteStreamDataObjectImpl
extends DataObjectImpl
implements BinaryDataObject {
/** The InputStream
containing the binary data. */
private InputStream inputStream;
/**
* Create a new ByteStreamDataObjectImpl
.
*
* @param inputStream The stream from which to read the binary data.
*/
public ByteStreamDataObjectImpl(InputStream inputStream) {
setInputStream(inputStream);
}
/**
* Set the input stream from which to read the binary data.
*
* @param inputStream The input stream from which to read the binary data.
*/
public void setInputStream(InputStream inputStream) {
this.inputStream = inputStream;
}
/**
* Return the binary data from this object as a stream.
*
* @return The stream containing the binary data. Calling this function
* repeatedly will always return the same InputStream
.
* @see iaik.server.modules.xml.BinaryDataObject#getInputStream()
*/
public InputStream getInputStream() {
return inputStream;
}
}