Package jakarta.servlet.http
Class NoBodyOutputStream
- java.lang.Object
-
- java.io.OutputStream
-
- jakarta.servlet.ServletOutputStream
-
- jakarta.servlet.http.NoBodyOutputStream
-
- All Implemented Interfaces:
java.io.Closeable
,java.io.Flushable
,java.lang.AutoCloseable
class NoBodyOutputStream extends ServletOutputStream
-
-
Field Summary
Fields Modifier and Type Field Description private int
contentLength
private static java.lang.String
LSTRING_FILE
private static java.util.ResourceBundle
lStrings
-
Constructor Summary
Constructors Constructor Description NoBodyOutputStream()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) int
getContentLength()
boolean
isReady()
This method can be used to determine if data can be written without blocking.void
setWriteListener(WriteListener writeListener)
Instructs theServletOutputStream
to invoke the providedWriteListener
when it is possible to writevoid
write(byte[] buf, int offset, int len)
void
write(int b)
-
-
-
Field Detail
-
LSTRING_FILE
private static final java.lang.String LSTRING_FILE
- See Also:
- Constant Field Values
-
lStrings
private static java.util.ResourceBundle lStrings
-
contentLength
private int contentLength
-
-
Method Detail
-
getContentLength
int getContentLength()
-
write
public void write(int b)
- Specified by:
write
in classjava.io.OutputStream
-
write
public void write(byte[] buf, int offset, int len) throws java.io.IOException
- Overrides:
write
in classjava.io.OutputStream
- Throws:
java.io.IOException
-
isReady
public boolean isReady()
Description copied from class:ServletOutputStream
This method can be used to determine if data can be written without blocking.- Specified by:
isReady
in classServletOutputStream
- Returns:
true
if a write to thisServletOutputStream
will succeed, otherwise returnsfalse
.
-
setWriteListener
public void setWriteListener(WriteListener writeListener)
Description copied from class:ServletOutputStream
Instructs theServletOutputStream
to invoke the providedWriteListener
when it is possible to write- Specified by:
setWriteListener
in classServletOutputStream
- Parameters:
writeListener
- theWriteListener
that should be notified when it's possible to write
-
-