|
XNIO API 3.0.7.GA | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.xnio.TranslatingResult<T,O>
T - the result type to acceptO - the result type to pass to the delegatepublic abstract class TranslatingResult<T,O>
Abstract base class for Results which translate from one type to another.
| Constructor Summary | |
|---|---|
protected |
TranslatingResult(Result<O> output)
|
| Method Summary | |
|---|---|
boolean |
setCancelled()
Acknowledge the cancellation of this operation. |
boolean |
setException(IOException exception)
Set the exception for this operation. |
boolean |
setResult(T result)
Set the result for this operation. |
protected abstract O |
translate(T input)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected TranslatingResult(Result<O> output)
| Method Detail |
|---|
public boolean setException(IOException exception)
Result
setException in interface Result<T>exception - the exception to set
false if the operation was already completed, true otherwisepublic boolean setCancelled()
Result
setCancelled in interface Result<T>false if the operation was already completed, true otherwisepublic boolean setResult(T result)
Result
setResult in interface Result<T>result - the result to set
false if the operation was already completed, true otherwise
protected abstract O translate(T input)
throws IOException
IOException
|
XNIO API 3.0.7.GA | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||