org.jboss.solder.exception.control
Class HandlerMethodImpl<T extends Throwable>

java.lang.Object
  extended by org.jboss.solder.exception.control.HandlerMethodImpl<T>
Type Parameters:
T - Type of the exception this handler handles.
All Implemented Interfaces:
org.jboss.solder.exception.control.HandlerMethod<T>

public class HandlerMethodImpl<T extends Throwable>
extends Object
implements org.jboss.solder.exception.control.HandlerMethod<T>

Implementation of HandlerMethod.


Constructor Summary
HandlerMethodImpl(javax.enterprise.inject.spi.AnnotatedMethod<?> method, javax.enterprise.inject.spi.BeanManager bm)
          Sole Constructor.
 
Method Summary
 boolean equals(Object o)
           
static javax.enterprise.inject.spi.AnnotatedParameter<?> findHandlerParameter(javax.enterprise.inject.spi.AnnotatedMethod<?> method)
           
 javax.enterprise.inject.spi.Bean<?> getBean(javax.enterprise.inject.spi.BeanManager bm)
          
 Class<?> getBeanClass()
          
 Type getExceptionType()
          
 javax.enterprise.inject.spi.AnnotatedParameter<?> getHandlerParameter()
           
 Set<javax.enterprise.inject.spi.InjectionPoint> getInjectionPoints()
           
 Method getJavaMethod()
          
 int getPrecedence()
          
 Set<Annotation> getQualifiers()
          
 org.jboss.solder.exception.control.TraversalMode getTraversalMode()
          
 int hashCode()
           
static boolean isHandler(javax.enterprise.inject.spi.AnnotatedMethod<?> method)
          Determines if the given method is a handler by looking for the Handles annotation on a parameter.
 void notify(org.jboss.solder.exception.control.CaughtException<T> event, javax.enterprise.inject.spi.BeanManager bm)
          
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

HandlerMethodImpl

public HandlerMethodImpl(javax.enterprise.inject.spi.AnnotatedMethod<?> method,
                         javax.enterprise.inject.spi.BeanManager bm)
Sole Constructor.

Parameters:
method - found handler
bm - active BeanManager
Throws:
IllegalArgumentException - if method is null, has no params or first param is not annotated with Handles
Method Detail

isHandler

public static boolean isHandler(javax.enterprise.inject.spi.AnnotatedMethod<?> method)
Determines if the given method is a handler by looking for the Handles annotation on a parameter.

Parameters:
method - method to search
Returns:
true if Handles is found, false otherwise

findHandlerParameter

public static javax.enterprise.inject.spi.AnnotatedParameter<?> findHandlerParameter(javax.enterprise.inject.spi.AnnotatedMethod<?> method)

getBeanClass

public Class<?> getBeanClass()


getBean

public javax.enterprise.inject.spi.Bean<?> getBean(javax.enterprise.inject.spi.BeanManager bm)


getQualifiers

public Set<Annotation> getQualifiers()

Specified by:
getQualifiers in interface org.jboss.solder.exception.control.HandlerMethod<T extends Throwable>

getExceptionType

public Type getExceptionType()

Specified by:
getExceptionType in interface org.jboss.solder.exception.control.HandlerMethod<T extends Throwable>

notify

public void notify(org.jboss.solder.exception.control.CaughtException<T> event,
                   javax.enterprise.inject.spi.BeanManager bm)

Specified by:
notify in interface org.jboss.solder.exception.control.HandlerMethod<T extends Throwable>

getTraversalMode

public org.jboss.solder.exception.control.TraversalMode getTraversalMode()

Specified by:
getTraversalMode in interface org.jboss.solder.exception.control.HandlerMethod<T extends Throwable>

getPrecedence

public int getPrecedence()

Specified by:
getPrecedence in interface org.jboss.solder.exception.control.HandlerMethod<T extends Throwable>

getJavaMethod

public Method getJavaMethod()


getHandlerParameter

public javax.enterprise.inject.spi.AnnotatedParameter<?> getHandlerParameter()

getInjectionPoints

public Set<javax.enterprise.inject.spi.InjectionPoint> getInjectionPoints()

equals

public boolean equals(Object o)
Specified by:
equals in interface org.jboss.solder.exception.control.HandlerMethod<T extends Throwable>
Overrides:
equals in class Object

hashCode

public int hashCode()
Specified by:
hashCode in interface org.jboss.solder.exception.control.HandlerMethod<T extends Throwable>
Overrides:
hashCode in class Object

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2008-2011 Seam Framework. All Rights Reserved.