public abstract class AbstractRequest<T> extends Object implements Request<T>
| Constructor and Description |
|---|
AbstractRequest()
Derived classes must call this constructor via super() if they want to get
the benefit of delegate handling.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
canBeCancelled()
A request object may be canceled if this method returns true.
|
void |
cancel()
Cancel the current request; this implementation will always throw an
IllegalStateException.
|
boolean |
equals(Object pOther)
A AbstractRequest is equal to an other AbstractRequest if their
delegates and dispatch targets are equal.
|
RequestDelegate<T> |
getDelegate()
Returns our request delegate.
|
DispatchTarget |
getDispatchTarget()
Returns our dispatch target.
|
int |
hashCode() |
void |
setDispatchTarget(DispatchTarget pTarget)
Sets our dispatch target.
|
void |
setDispatchTarget(Object pTargetObject,
String pMethodName)
Sets our dispatch target.
|
String |
toString()
Returns a String representation of this AbstractRequest.
|
public AbstractRequest()
public void setDispatchTarget(DispatchTarget pTarget)
setDispatchTarget in interface Request<T>pTarget - the target to set (null is o.k.)public void setDispatchTarget(Object pTargetObject, String pMethodName)
setDispatchTarget in interface Request<T>pTargetObject - target to call, must not be nullpMethodName - method to call, must not be null and match the
void public DispatchTarget getDispatchTarget()
getDispatchTarget in interface Request<T>public RequestDelegate<T> getDelegate()
getDelegate in interface Request<T>public boolean canBeCancelled()
canBeCancelled in interface Request<T>public void cancel()
throws IllegalStateException
cancel in interface Request<T>IllegalStateException - always thrownpublic boolean equals(Object pOther)
Copyright © 2016 Jürgen Zeller (privat). All rights reserved.