Top Fields Constructors Methods
org.eclipse.jetty.server.handler

public Class ContextResponse

extends Wrapper
Class Inheritance
Imports
java.nio.ByteBuffer, org.eclipse.jetty.server.Request, .Response, org.eclipse.jetty.util.Callback, org.eclipse.jetty.util.thread.Invocable

Field Summary

Modifier and TypeField and Description
private final ContextHandler.ScopedContext

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public void
write(boolean
whether the ByteBuffer is the last to write
last
,
ByteBuffer
the ByteBuffer to write
content
,
Callback
the callback to notify when the write operation is complete
callback
)

Overrides org.eclipse.jetty.server.Response.Wrapper.write.

Implements org.eclipse.jetty.server.Response.write.

Writes the given ByteBuffer, notifying the Callback when the write is complete.

Inherited from org.eclipse.jetty.server.Response.Wrapper:
getHeadersgetRequestgetStatusgetTrailersSuppliergetWrappedhasLastWriteisCommittedisCompletedSuccessfullyresetsetStatussetTrailersSupplierwriteInterim

Field Detail

_contextback to summary
private final ContextHandler.ScopedContext _context

Constructor Detail

ContextResponseback to summary
public ContextResponse(ContextHandler.ScopedContext context, Request request, Response response)

Method Detail

writeback to summary
public void write(boolean last, ByteBuffer content, Callback callback)

Overrides org.eclipse.jetty.server.Response.Wrapper.write.

Implements org.eclipse.jetty.server.Response.write.

Doc from org.eclipse.jetty.server.Response.write.

Writes the given ByteBuffer, notifying the Callback when the write is complete.

Implementations guarantee that calls to this method are safely reentrant so that stack overflows are avoided in the case of mutual recursion between the execution of the Callback and a call to this method.

The invocation of the passed Callback is serialized with previous calls of this method, so that it is not invoked until any invocation of the callback of a previous call to this method has returned.

Thus a Callback should not block waiting for a callback of a future call to this method.

Parameters
last:boolean

whether the ByteBuffer is the last to write

content:ByteBuffer

the ByteBuffer to write

callback:Callback

the callback to notify when the write operation is complete

Annotations
@Override