public final class RequestEnvelope extends Envelope<Request<?,?>>
| Constructor and Description |
|---|
RequestEnvelope(Request<?,?> message,
long sessionId,
long txSequence) |
| Modifier and Type | Method and Description |
|---|---|
ResponseEnvelope<?> |
newSuccessEnvelope(RequestSuccess<?,?> success,
long executionTimeNanos)
Creates a successful ResponseEnvelope that wraps the given successful Request response message.
|
void |
sendFailure(RequestException cause,
long executionTimeNanos)
Respond to this envelope with a
RequestFailure caused by specified RequestException. |
void |
sendSuccess(RequestSuccess<?,?> success,
long executionTimeNanos)
Respond to this envelope with a
RequestSuccess. |
getMessage, getSessionId, getTxSequence, toStringpublic RequestEnvelope(Request<?,?> message, long sessionId, long txSequence)
public void sendFailure(RequestException cause, long executionTimeNanos)
RequestFailure caused by specified RequestException.cause - Cause of this RequestFailureexecutionTimeNanos - Time to execute the request, in nanosecondsNullPointerException - if cause is nullpublic void sendSuccess(RequestSuccess<?,?> success, long executionTimeNanos)
RequestSuccess.success - Successful responseNullPointerException - if success is nullpublic ResponseEnvelope<?> newSuccessEnvelope(RequestSuccess<?,?> success, long executionTimeNanos)
success - the successful Request response messageexecutionTimeNanos - the execution time of the requestResponseEnvelope instanceCopyright © 2019 OpenDaylight. All rights reserved.