
Servlet::ServletOutputStream - servlet output stream interface

$stream->print($string); $stream->println(); $stream->println($string); $stream->write($string); $stream->write($string, $length); $stream->write($string, $length, $offset); $stream->flush(); $stream->close();

Provides an output stream for writing binary data to a servlet response.
An output stream object is normally retrieved via "getOutputStream" in Servlet::ServletResponse.
NOTE: While this is an abstract class in the Java API, the Perl API provides it as an interface. The main difference is that the Perl version has no constructor. Also, it merges the methods declared in java.io.OutputStream and javax.servlet.ServletOutputStream into a single interface.

Closes the stream and releases any system resources associated with the stream.
Throws:
if an output exception occurred
Flushes this input stream and forces any buffered output bytes to be written out.
Throws:
if an output exception occurred
Writes a scalar value to the client, with no carriage return-line feed (CRLF) character at the end.
Parameters:
the value to send to the client
Throws:
if an output exception occurred
Writes a scalar value to the client, if specified, followed by a carriage return-line feed (CRLF) character.
Parameters:
the (optional) value to send to the client
Throws:
if an output exception occurred
Writes the scalar $value to the stream.
If no arguments are specified, functions exactly equivalently to print().
If $length is specified, writes that many bytes from $value. If $offset is specified, starts writing that many bytes from the beginning of $value. $offset and $length must not be negative, and $length must not be greater than the amount of data in $value starting from $offset.
Blocks until input data is available, the end of the stream is detected, or an exception is thrown.
Parameters:
a scalar value to be written
the maximum number of bytes to write
the location in $value where data is read from
Throws:
if an input exception occurs
if $buffer is specified as undef

Servlet::ServletResponse, Servlet::Util::Exception

Brian Moseley, bcm@maz.org