org.objectweb.easybeans.deployment.annotations.helper.bean
Class InheritanceMethodResolver

java.lang.Object
  extended by org.objectweb.easybeans.deployment.annotations.helper.bean.InheritanceMethodResolver

public final class InheritanceMethodResolver
extends java.lang.Object

This class adds method meta data to bean class from the super class.
TODO: Try to analyze super class from a super classloader if not found in the current ejb-jar

Author:
Florent Benoit
See Also:
EJB 3.0 Spec ?4.6.2

A super class can't be a bean class (stateless, stateful, etc) so the method metadata don't need to be cloned


Field Summary
private static java.lang.String JAVA_LANG_OBJECT
          java.lang.object internal name.
 
Constructor Summary
private InheritanceMethodResolver()
          Helper class, no public constructor.
 
Method Summary
private static void addMethodMetadata(ClassAnnotationMetadata beanclassAnnotationMetadata, ClassAnnotationMetadata visitingClassAnnotationMetadata)
          Adds method meta data on the first class by iterating on the second given class.
static void resolve(ClassAnnotationMetadata classAnnotationMetadata)
          Found all method meta data of the super class and adds them to the class being analyzed.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

JAVA_LANG_OBJECT

private static final java.lang.String JAVA_LANG_OBJECT
java.lang.object internal name.

Constructor Detail

InheritanceMethodResolver

private InheritanceMethodResolver()
Helper class, no public constructor.

Method Detail

resolve

public static void resolve(ClassAnnotationMetadata classAnnotationMetadata)
                    throws ResolverException
Found all method meta data of the super class and adds them to the class being analyzed.

Parameters:
classAnnotationMetadata - class to analyze
Throws:
ResolverException - if the super class in not in the given ejb-jar

addMethodMetadata

private static void addMethodMetadata(ClassAnnotationMetadata beanclassAnnotationMetadata,
                                      ClassAnnotationMetadata visitingClassAnnotationMetadata)
                               throws ResolverException
Adds method meta data on the first class by iterating on the second given class.

Parameters:
beanclassAnnotationMetadata - class where to add method metadata
visitingClassAnnotationMetadata - takes method metadata from super class of the given class
Throws:
ResolverException - if a super class metadata is not found from ejb-jar