Class EntityServletOutputStream
- java.lang.Object
-
- java.io.OutputStream
-
- javax.servlet.ServletOutputStream
-
- org.sakaiproject.entitybroker.util.http.EntityServletOutputStream
-
- All Implemented Interfaces:
Closeable,Flushable,AutoCloseable
public class EntityServletOutputStream extends ServletOutputStream
This allows us to produce and controlServletOutputStreams, normally there is not a default implementation available for these for some crazed reason- Author:
- Aaron Zeckoski (azeckoski @ gmail.com)
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classEntityServletOutputStream.WriterOutputStreamWrap a Writer as an OutputStream.
-
Constructor Summary
Constructors Constructor Description EntityServletOutputStream()Create a SOS with a default BOS as the storage mechanism for itEntityServletOutputStream(OutputStream outputStream)Create the SOS from an existing outputstreamEntityServletOutputStream(Writer writer)Creates the SOS from an existing writer
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()booleanequals(Object obj)voidflush()inthashCode()StringtoString()voidwrite(byte[] b)voidwrite(byte[] b, int off, int len)voidwrite(int b)-
Methods inherited from class javax.servlet.ServletOutputStream
print, print, print, print, print, print, print, println, println, println, println, println, println, println, println
-
Methods inherited from class java.io.OutputStream
nullOutputStream
-
-
-
-
Constructor Detail
-
EntityServletOutputStream
public EntityServletOutputStream()
Create a SOS with a default BOS as the storage mechanism for it
-
EntityServletOutputStream
public EntityServletOutputStream(OutputStream outputStream)
Create the SOS from an existing outputstream- Parameters:
outputStream- the OS to create the SOS from, can be buffered or not
-
EntityServletOutputStream
public EntityServletOutputStream(Writer writer)
Creates the SOS from an existing writer- Parameters:
writer- any writer
-
-
Method Detail
-
close
public void close() throws IOException- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classOutputStream- Throws:
IOException
-
flush
public void flush() throws IOException- Specified by:
flushin interfaceFlushable- Overrides:
flushin classOutputStream- Throws:
IOException
-
write
public void write(byte[] b, int off, int len) throws IOException- Overrides:
writein classOutputStream- Throws:
IOException
-
write
public void write(byte[] b) throws IOException- Overrides:
writein classOutputStream- Throws:
IOException
-
write
public void write(int b) throws IOException- Specified by:
writein classOutputStream- Throws:
IOException
-
-