Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.tapestry5.ioc
Interface Invocation

All Known Subinterfaces:
  ComponentMethodInvocation

Deprecated. Deprecated in 5.3, to be removed in 5.4. Replaced with `MethodInvocation`.

    public interface Invocation

A method invocation passed to a `MethodAdvice`.

Method Summary
`
`<T extends java.lang.annotation.Annotation> T`
` | `getMethodAnnotation(java.lang.Class<T> annotationClass)` Deprecated. Returns the annotation, placed on the method being invoked, for the specified type.
`java.lang.String` | `getMethodName()` Deprecated. Returns the name of the method being invoked.
`java.lang.Object` | `getParameter(int index)` Deprecated. Returns the indicated parameter (may return null if the parameter is null).
`int` | `getParameterCount()` Deprecated. Returns the number of parameters passed to the method.
`java.lang.Class` | `getParameterType(int index)` Deprecated. Returns the type of the parameter at the index.
`java.lang.Object` | `getResult()` Deprecated. The return value after `proceed()`, which may be null.
`java.lang.Class` | `getResultType()` Deprecated. Returns the type of the method result, which may be a primitive type (i.e., int.class) or even void (void.class).
`
`<T extends java.lang.Throwable> T`
` | `getThrown(java.lang.Class<T> throwableClass)` Deprecated. After invoking `proceed()`, used to obtain the thrown (checked) exception, if assignable to the provided type.
`boolean` | `isFail()` Deprecated. If true, then the proceeded invocation threw a checked exception.
`void` | `override(int index, java.lang.Object newParameter)` Deprecated. Replaces a parameter in the invocation.
`void` | `overrideResult(java.lang.Object newResult)` Deprecated. Overrides the result.
`void` | `overrideThrown(java.lang.Exception thrown)` Deprecated. Overrides the thrown exception.
`void` | `proceed()` Deprecated. Proceed with the invocation of the advised method.
`void` | `rethrow()` Deprecated. If the invocation failed (with a checked exception), then rethrow the exception wrapped in a RuntimeException.

Method Detail

### getMethodName

    java.lang.String getMethodName()

  Deprecated.
  Returns the name of the method being invoked.

### getResultType

    java.lang.Class getResultType()

  Deprecated.
  Returns the type of the method result, which may be a primitive type (i.e., int.class) or even void (void.class).

### getParameterCount

    int getParameterCount()

  Deprecated.
  Returns the number of parameters passed to the method.

### getParameterType

    java.lang.Class getParameterType(int index)

  Deprecated.
  Returns the type of the parameter at the index.

### getParameter

    java.lang.Object getParameter(int index)

  Deprecated.
  Returns the indicated parameter (may return null if the parameter is null).

### override

    void override(int index,
                  java.lang.Object newParameter)

  Deprecated.
  Replaces a parameter in the invocation.

  Parameters:
    `index` - of parameter to update
    `newParameter` - new parameter value (may be null)

### proceed

    void proceed()

  Deprecated.
  Proceed with the invocation of the advised method. If the invocation results in a runtime exception, that is thrown. A checked exception is detected by invoking `isFail()`.

### isFail

    boolean isFail()

  Deprecated.
  If true, then the proceeded invocation threw a checked exception.

### rethrow

    void rethrow()

  Deprecated.
  If the invocation failed (with a checked exception), then rethrow the exception wrapped in a RuntimeException.

  Since:
    5.2.0

### getThrown

    <T extends java.lang.Throwable> T getThrown(java.lang.Class<T> throwableClass)

  Deprecated.
  After invoking `proceed()`, used to obtain the thrown (checked) exception, if assignable to the provided type.

  Parameters:
    `throwableClass` - the type of exception to match
  Returns:
    the exception, if the proceeded invocation threw a checked exception, and the exception is assignable to the provided type. In other cases, null is returned.

### overrideThrown

    void overrideThrown(java.lang.Exception thrown)

  Deprecated.
  Overrides the thrown exception. The passed exception should be a checked exception of the method. Note that for runtime exceptions, or even `Error`s, those can just be thrown. Sets the fail flag.

  Parameters:
    `thrown` -
  Throws:
    `java.lang.IllegalArgumentException` - if thrown is null, or not a declared exception of the method

### getResult

    java.lang.Object getResult()

  Deprecated.
  The return value after `proceed()`, which may be null.

### overrideResult

    void overrideResult(java.lang.Object newResult)

  Deprecated.
  Overrides the result. Clears the thrown exception (if any).

### getMethodAnnotation

    <T extends java.lang.annotation.Annotation> T getMethodAnnotation(java.lang.Class<T> annotationClass)

  Deprecated.
  Returns the annotation, placed on the method being invoked, for the specified type. If such an annotation is present, else null.

  Parameters:
    `annotationClass` - the Class object corresponding to the annotation type
  Returns:
    method's annotation for the specified annotation type if present on this element, else null
  Since:
    5.3

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2003-2012 The Apache Software Foundation.