|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.tapestry5.ioc.internal.services.AbstractInvocation
public abstract class AbstractInvocation
Base class for Invocation, which is extended with a dynamically generated class
generated for each individual class and method.
| Constructor Summary | |
|---|---|
protected |
AbstractInvocation(MethodInfo methodInfo)
|
| Method Summary | ||
|---|---|---|
java.lang.String |
getMethodName()
Returns the name of the method being invoked. |
|
int |
getParameterCount()
Returns the number of parameters passed to the method. |
|
java.lang.Class |
getParameterType(int index)
Returns the type of the parameter at the index. |
|
java.lang.Object |
getResult()
The return value after Invocation.proceed(), which may be null. |
|
java.lang.Class |
getResultType()
Returns the type of the method result, which may be a primitive type (i.e., int.class) or even void (void.class). |
|
|
getThrown(java.lang.Class<T> throwableClass)
After invoking Invocation.proceed(), used to obtain the thrown (checked) exception, if assignable to the provided
type. |
|
protected abstract void |
invokeDelegateMethod()
This method is filled in, in the dynamically generated subclass. |
|
boolean |
isFail()
If true, then the proceeded invocation threw a checked exception. |
|
void |
overrideResult(java.lang.Object newResult)
Overrides the result. |
|
void |
overrideThrown(java.lang.Exception thrown)
Overrides the thrown exception. |
|
void |
proceed()
Proceed with the invocation of the advised method. |
|
void |
rethrow()
If the invocation failed (with a checked exception), then rethrow the exception wrapped in a RuntimeException. |
|
java.lang.String |
toString()
|
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.apache.tapestry5.ioc.Invocation |
|---|
getParameter, override |
| Constructor Detail |
|---|
protected AbstractInvocation(MethodInfo methodInfo)
| Method Detail |
|---|
public java.lang.String toString()
toString in class java.lang.Objectpublic java.lang.String getMethodName()
Invocation
getMethodName in interface Invocationpublic java.lang.Class getResultType()
Invocation
getResultType in interface Invocationpublic int getParameterCount()
Invocation
getParameterCount in interface Invocationpublic java.lang.Class getParameterType(int index)
Invocation
getParameterType in interface Invocationpublic boolean isFail()
Invocation
isFail in interface Invocationpublic void rethrow()
Invocation
rethrow in interface Invocationpublic <T extends java.lang.Throwable> T getThrown(java.lang.Class<T> throwableClass)
InvocationInvocation.proceed(), used to obtain the thrown (checked) exception, if assignable to the provided
type.
getThrown in interface InvocationthrowableClass - the type of exception to match
public void overrideThrown(java.lang.Exception thrown)
InvocationErrors, those can just be thrown. Sets the fail flag.
overrideThrown in interface Invocationpublic java.lang.Object getResult()
InvocationInvocation.proceed(), which may be null.
getResult in interface Invocationpublic void overrideResult(java.lang.Object newResult)
Invocation
overrideResult in interface Invocationpublic void proceed()
InvocationInvocation.isFail().
proceed in interface Invocationprotected abstract void invokeDelegateMethod()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||