org.codehaus.aspectwerkz.transform.inlining.spi
Interface AspectModel


public interface AspectModel

TODO document

Author:
Jonas BonŽr

Nested Class Summary
static class AspectModel.AroundClosureClassInfo
          Info about the around closure class or interface for this specific aspect model.
 
Method Summary
 void createAfterAdviceArgumentHandling(org.objectweb.asm.CodeVisitor cv, AdviceMethodInfo adviceMethodInfo)
          Handles the arguments to the after advice.
 void createAroundAdviceArgumentHandling(org.objectweb.asm.CodeVisitor cv, AdviceMethodInfo adviceMethodInfo)
          Handles the arguments to the around advice.
 void createAspectInstantiation(org.objectweb.asm.CodeVisitor cv, AspectInfo aspectInfo, String joinPointClassName)
          Creates instantiation of an aspect instance.
 void createAspectReferenceField(org.objectweb.asm.ClassWriter cw, AspectInfo aspectInfo, String joinPointClassName)
          Creates aspect reference field (field in the jit jointpoint class f.e.) for an aspect instance.
 void createBeforeAdviceArgumentHandling(org.objectweb.asm.CodeVisitor cv, AdviceMethodInfo adviceMethodInfo)
          Handles the arguments to the after advice.
 void createInvocationOfAroundClosureSuperClass(org.objectweb.asm.CodeVisitor cv)
          Creates invocation of the super class for the around closure.
 void createMandatoryMethods(org.objectweb.asm.ClassWriter cw, String className)
          Creates the methods required to implement or extend to implement the closure for the specific aspect model type.
 void defineAspect(ClassInfo aspectClassInfo, AspectDefinition aspectDef, ClassLoader loader)
          Defines the aspect and adds definition to the aspect definition.
 AspectModel.AroundClosureClassInfo getAroundClosureClassInfo()
          Returns info about the closure class, name and type (interface or class).
 String getAspectModelType()
          Returns the aspect model type, which is an id for the the special aspect model, can be anything as long as it is unique.
 boolean requiresReflectiveInfo()
          Should return true if the aspect model requires that Runtime Type Information (RTTI) is build up for the join point.
 

Method Detail

getAspectModelType

String getAspectModelType()
Returns the aspect model type, which is an id for the the special aspect model, can be anything as long as it is unique.

Returns:
the aspect model type id

defineAspect

void defineAspect(ClassInfo aspectClassInfo,
                  AspectDefinition aspectDef,
                  ClassLoader loader)
Defines the aspect and adds definition to the aspect definition.

Parameters:
aspectClassInfo -
aspectDef -
loader -

getAroundClosureClassInfo

AspectModel.AroundClosureClassInfo getAroundClosureClassInfo()
Returns info about the closure class, name and type (interface or class).

Returns:
the closure class info

createMandatoryMethods

void createMandatoryMethods(org.objectweb.asm.ClassWriter cw,
                            String className)
Creates the methods required to implement or extend to implement the closure for the specific aspect model type.

Parameters:
cw -
className -

createInvocationOfAroundClosureSuperClass

void createInvocationOfAroundClosureSuperClass(org.objectweb.asm.CodeVisitor cv)
Creates invocation of the super class for the around closure.

E.g. the invocation of super(..) in the constructor.

Only needed to be implemented if the around closure base class is really a base class and not an interface.

Parameters:
cv -

createAspectReferenceField

void createAspectReferenceField(org.objectweb.asm.ClassWriter cw,
                                AspectInfo aspectInfo,
                                String joinPointClassName)
Creates aspect reference field (field in the jit jointpoint class f.e.) for an aspect instance.

Parameters:
cw -
aspectInfo -
joinPointClassName -

createAspectInstantiation

void createAspectInstantiation(org.objectweb.asm.CodeVisitor cv,
                               AspectInfo aspectInfo,
                               String joinPointClassName)
Creates instantiation of an aspect instance.

Parameters:
cv -
aspectInfo -
joinPointClassName -

createAroundAdviceArgumentHandling

void createAroundAdviceArgumentHandling(org.objectweb.asm.CodeVisitor cv,
                                        AdviceMethodInfo adviceMethodInfo)
Handles the arguments to the around advice.

Parameters:
cv -
adviceMethodInfo -

createBeforeAdviceArgumentHandling

void createBeforeAdviceArgumentHandling(org.objectweb.asm.CodeVisitor cv,
                                        AdviceMethodInfo adviceMethodInfo)
Handles the arguments to the after advice.

Parameters:
cv -
adviceMethodInfo -

createAfterAdviceArgumentHandling

void createAfterAdviceArgumentHandling(org.objectweb.asm.CodeVisitor cv,
                                       AdviceMethodInfo adviceMethodInfo)
Handles the arguments to the after advice.

Parameters:
cv -
adviceMethodInfo -

requiresReflectiveInfo

boolean requiresReflectiveInfo()
Should return true if the aspect model requires that Runtime Type Information (RTTI) is build up for the join point. Needed for reflective systems and systems that does not support f.e. args() binding.

Returns:


Copyright © 2002-2005 Jonas Bonér, Alexandre Vasseur. All Rights Reserved.