public class SynchronousExecutionContext extends AbstractExecutionContext
Modifier and Type | Class and Description |
---|---|
protected class |
SynchronousExecutionContext.SynchronousAsynchronousResponse |
Modifier and Type | Field and Description |
---|---|
protected ResteasyAsynchronousResponse |
asynchronousResponse |
protected boolean |
done |
protected java.lang.Object |
responseLock |
protected java.util.concurrent.CountDownLatch |
syncLatch |
protected long |
timeout |
protected java.util.concurrent.TimeUnit |
timeoutUnit |
protected boolean |
wasSuspended |
dispatcher, request, response
Constructor and Description |
---|
SynchronousExecutionContext(SynchronousDispatcher dispatcher,
HttpRequest request,
HttpResponse response) |
Modifier and Type | Method and Description |
---|---|
ResteasyAsynchronousResponse |
getAsyncResponse() |
boolean |
isSuspended() |
ResteasyAsynchronousResponse |
suspend() |
ResteasyAsynchronousResponse |
suspend(long millis) |
ResteasyAsynchronousResponse |
suspend(long time,
java.util.concurrent.TimeUnit unit) |
protected final java.util.concurrent.CountDownLatch syncLatch
protected long timeout
protected java.util.concurrent.TimeUnit timeoutUnit
protected boolean wasSuspended
protected volatile boolean done
protected java.lang.Object responseLock
protected ResteasyAsynchronousResponse asynchronousResponse
public SynchronousExecutionContext(SynchronousDispatcher dispatcher, HttpRequest request, HttpResponse response)
public ResteasyAsynchronousResponse suspend() throws java.lang.IllegalStateException
java.lang.IllegalStateException
public ResteasyAsynchronousResponse suspend(long millis) throws java.lang.IllegalStateException
java.lang.IllegalStateException
public ResteasyAsynchronousResponse suspend(long time, java.util.concurrent.TimeUnit unit) throws java.lang.IllegalStateException
java.lang.IllegalStateException
public ResteasyAsynchronousResponse getAsyncResponse()
public boolean isSuspended()