Java Doc for AbstractJoinPointCompiler.java in  » Net » Terracotta » com » tc » aspectwerkz » transform » inlining » compiler » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Net » Terracotta » com.tc.aspectwerkz.transform.inlining.compiler 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   com.tc.aspectwerkz.transform.inlining.compiler.AbstractJoinPointCompiler

All known Subclasses:   com.tc.aspectwerkz.transform.inlining.compiler.ConstructorCallJoinPointCompiler,  com.tc.aspectwerkz.transform.inlining.compiler.MethodExecutionJoinPointCompiler,  com.tc.aspectwerkz.transform.inlining.compiler.HandlerJoinPointCompiler,  com.tc.aspectwerkz.transform.inlining.compiler.FieldSetJoinPointCompiler,  com.tc.aspectwerkz.transform.inlining.compiler.StaticInitializationJoinPointCompiler,  com.tc.aspectwerkz.transform.inlining.compiler.MethodCallJoinPointCompiler,  com.tc.aspectwerkz.transform.inlining.compiler.ConstructorExecutionJoinPointCompiler,  com.tc.aspectwerkz.transform.inlining.compiler.FieldGetJoinPointCompiler,
AbstractJoinPointCompiler
abstract public class AbstractJoinPointCompiler implements JoinPointCompiler,TransformationConstants(Code)
Abstract base class for the different join point compiler implementations.

Compiles/generates a class that represents a specific join point, a class which invokes the advices and the target join point statically.

FIXME: depending on hotswap needs, remove the implements StaticJP or JP decision
author:
   Jonas BonŽr
author:
   Alexandre Vasseur
author:
   Alex Popescu



Field Summary
final public static  booleanDUMP_JP_CLASSES
    
protected  AdviceMethodInfo[]m_afterFinallyAdviceMethodInfos
    
protected  AdviceMethodInfo[]m_afterReturningAdviceMethodInfos
    
protected  AdviceMethodInfo[]m_afterThrowingAdviceMethodInfos
    
public  Type[]m_argumentTypes
    
protected  AdviceMethodInfo[]m_aroundAdviceMethodInfos
    
protected  AspectInfo[]m_aspectInfos
    
protected  AspectModel[]m_aspectModels
    
protected  AdviceMethodInfo[]m_beforeAdviceMethodInfos
    
final protected  Stringm_calleeClassName
    
final public  Stringm_calleeClassSignature
    
final protected  Stringm_calleeMemberDesc
    
final protected  intm_calleeMemberModifiers
    
final protected  Stringm_calleeMemberName
    
final protected  Stringm_callerClassName
    
final public  Stringm_callerClassSignature
    
final protected  Stringm_callerMethodDesc
    
final protected  intm_callerMethodModifiers
    
final protected  Stringm_callerMethodName
    
protected  ClassWriterm_cw
    
public  String[]m_fieldNames
    
protected  booleanm_hasAroundAdvices
    
protected  booleanm_isThisAdvisable
    
final public  Stringm_joinPointClassName
    
final protected  intm_joinPointHash
    
final protected  intm_joinPointType
    
protected  booleanm_requiresJoinPoint
    
protected  booleanm_requiresProceedMethod
    
protected  booleanm_requiresThisOrTarget
    
protected  Typem_returnType
    

Constructor Summary
public  AbstractJoinPointCompiler(CompilationInfo.Model model)
     Creates a new join point compiler instance.

Method Summary
protected  StringbuildInvokeMethodSignature()
     Build up the signature of the 'invoke' methods.
final public  byte[]compile()
     Compiles a join point class, one specific class for each distinct join point.
final public  voidcreateArgumentArrayAt(MethodVisitor cv, int stackFreeIndex)
     Create and load a structure (f.e.
abstract protected  voidcreateGetRttiMethod()
    
abstract protected  voidcreateGetSignatureMethod()
    
abstract protected  voidcreateInlinedJoinPointInvocation(MethodVisitor cv, CompilerInput input)
     Optimized implementation that does not retrieve the parameters from the join point instance but is passed directly to the method from the input parameters in the 'invoke' method.
protected  voidcreateInvokeMethod()
     Creates the 'invoke' method.
abstract protected  voidcreateJoinPointInvocation(MethodVisitor cv)
     Creates a call to the target join point, the parameter(s) to the join point are retrieved from the invocation local join point instance.
abstract protected  voidcreateJoinPointSpecificFields()
     Creates join point specific fields.
abstract protected  voidcreateSignature(MethodVisitor cv)
     Creates the signature for the join point.
final public  AspectModel[]getAspectModels()
    
public  StringgetCalleeClassName()
    
public  StringgetCalleeClassSignature()
    
public  StringgetCallerClassName()
    
public  StringgetCallerClassSignature()
    
abstract protected  Type[]getJoinPointArgumentTypes()
     Returns the join points argument type(s).
public  StringgetJoinPointClassName()
    
abstract protected  TypegetJoinPointReturnType()
     Returns the join points return type.
final protected  voidloadArgumentMemberFields(MethodVisitor cv, int argStartIndex)
     Loads the argument member fields.
final protected  voidloadArguments(MethodVisitor cv)
     Loads the arguments.
public static  voidloadCallee(MethodVisitor cv, CompilerInput input)
    
public static  voidloadCaller(MethodVisitor cv, CompilerInput input)
    
public static  voidloadJoinPointInstance(MethodVisitor cv, CompilerInput input)
     Loads the join point instance, takes static/non-static join point access into account.
public static  booleanrequiresCalleeInstance(DeploymentModel deployModel)
    
public static  booleanrequiresCallerInstance(DeploymentModel deployModel)
    
public static  booleanrequiresCallerOrCallee(DeploymentModel deploymentModel)
    

Field Detail
DUMP_JP_CLASSES
final public static boolean DUMP_JP_CLASSES(Code)



m_afterFinallyAdviceMethodInfos
protected AdviceMethodInfo[] m_afterFinallyAdviceMethodInfos(Code)



m_afterReturningAdviceMethodInfos
protected AdviceMethodInfo[] m_afterReturningAdviceMethodInfos(Code)



m_afterThrowingAdviceMethodInfos
protected AdviceMethodInfo[] m_afterThrowingAdviceMethodInfos(Code)



m_argumentTypes
public Type[] m_argumentTypes(Code)



m_aroundAdviceMethodInfos
protected AdviceMethodInfo[] m_aroundAdviceMethodInfos(Code)



m_aspectInfos
protected AspectInfo[] m_aspectInfos(Code)



m_aspectModels
protected AspectModel[] m_aspectModels(Code)



m_beforeAdviceMethodInfos
protected AdviceMethodInfo[] m_beforeAdviceMethodInfos(Code)



m_calleeClassName
final protected String m_calleeClassName(Code)



m_calleeClassSignature
final public String m_calleeClassSignature(Code)



m_calleeMemberDesc
final protected String m_calleeMemberDesc(Code)



m_calleeMemberModifiers
final protected int m_calleeMemberModifiers(Code)



m_calleeMemberName
final protected String m_calleeMemberName(Code)



m_callerClassName
final protected String m_callerClassName(Code)



m_callerClassSignature
final public String m_callerClassSignature(Code)



m_callerMethodDesc
final protected String m_callerMethodDesc(Code)



m_callerMethodModifiers
final protected int m_callerMethodModifiers(Code)



m_callerMethodName
final protected String m_callerMethodName(Code)



m_cw
protected ClassWriter m_cw(Code)



m_fieldNames
public String[] m_fieldNames(Code)



m_hasAroundAdvices
protected boolean m_hasAroundAdvices(Code)



m_isThisAdvisable
protected boolean m_isThisAdvisable(Code)



m_joinPointClassName
final public String m_joinPointClassName(Code)



m_joinPointHash
final protected int m_joinPointHash(Code)



m_joinPointType
final protected int m_joinPointType(Code)



m_requiresJoinPoint
protected boolean m_requiresJoinPoint(Code)



m_requiresProceedMethod
protected boolean m_requiresProceedMethod(Code)



m_requiresThisOrTarget
protected boolean m_requiresThisOrTarget(Code)



m_returnType
protected Type m_returnType(Code)




Constructor Detail
AbstractJoinPointCompiler
public AbstractJoinPointCompiler(CompilationInfo.Model model)(Code)
Creates a new join point compiler instance.
Parameters:
  model - the compilation model




Method Detail
buildInvokeMethodSignature
protected String buildInvokeMethodSignature()(Code)
Build up the signature of the 'invoke' methods.



compile
final public byte[] compile()(Code)
Compiles a join point class, one specific class for each distinct join point. The compiled join point class inherits the base join point class. the generated, compiled and loaded join point class



createArgumentArrayAt
final public void createArgumentArrayAt(MethodVisitor cv, int stackFreeIndex)(Code)
Create and load a structure (f.e. array of Object) where args are stored, before setting the Rtti with it (See addParametersToRttiInstance). The structure is stored at the given stackFreeIndex.

Note: public for createMandatoryMethods in the models
Parameters:
  cv -
Parameters:
  stackFreeIndex -




createGetRttiMethod
abstract protected void createGetRttiMethod()(Code)
Creates the getRtti method



createGetSignatureMethod
abstract protected void createGetSignatureMethod()(Code)
Creates the getSignature method



createInlinedJoinPointInvocation
abstract protected void createInlinedJoinPointInvocation(MethodVisitor cv, CompilerInput input)(Code)
Optimized implementation that does not retrieve the parameters from the join point instance but is passed directly to the method from the input parameters in the 'invoke' method. Can only be used if no around advice exists.
Parameters:
  cv -
Parameters:
  input -



createInvokeMethod
protected void createInvokeMethod()(Code)
Creates the 'invoke' method. If possible delegates to the target join point directly, e.g. does not invoke the 'proceed' method (Used when a join point has zero around advice).

The implementation here is suitable for regular JP but not for delegating JP upon hotswap




createJoinPointInvocation
abstract protected void createJoinPointInvocation(MethodVisitor cv)(Code)
Creates a call to the target join point, the parameter(s) to the join point are retrieved from the invocation local join point instance.
Parameters:
  cv -



createJoinPointSpecificFields
abstract protected void createJoinPointSpecificFields()(Code)
Creates join point specific fields.



createSignature
abstract protected void createSignature(MethodVisitor cv)(Code)
Creates the signature for the join point.
Parameters:
  cv -



getAspectModels
final public AspectModel[] getAspectModels()(Code)



getCalleeClassName
public String getCalleeClassName()(Code)



getCalleeClassSignature
public String getCalleeClassSignature()(Code)



getCallerClassName
public String getCallerClassName()(Code)



getCallerClassSignature
public String getCallerClassSignature()(Code)



getJoinPointArgumentTypes
abstract protected Type[] getJoinPointArgumentTypes()(Code)
Returns the join points argument type(s).



getJoinPointClassName
public String getJoinPointClassName()(Code)



getJoinPointReturnType
abstract protected Type getJoinPointReturnType()(Code)
Returns the join points return type.



loadArgumentMemberFields
final protected void loadArgumentMemberFields(MethodVisitor cv, int argStartIndex)(Code)
Loads the argument member fields.
Parameters:
  cv -
Parameters:
  argStartIndex -



loadArguments
final protected void loadArguments(MethodVisitor cv)(Code)
Loads the arguments.
Parameters:
  cv -



loadCallee
public static void loadCallee(MethodVisitor cv, CompilerInput input)(Code)
Helper method to load the callee on the stack
Parameters:
  cv -
Parameters:
  input -



loadCaller
public static void loadCaller(MethodVisitor cv, CompilerInput input)(Code)
Helper method to load the caller on the stack
Parameters:
  cv -
Parameters:
  input -



loadJoinPointInstance
public static void loadJoinPointInstance(MethodVisitor cv, CompilerInput input)(Code)
Loads the join point instance, takes static/non-static join point access into account.
Parameters:
  cv -
Parameters:
  input -



requiresCalleeInstance
public static boolean requiresCalleeInstance(DeploymentModel deployModel)(Code)



requiresCallerInstance
public static boolean requiresCallerInstance(DeploymentModel deployModel)(Code)



requiresCallerOrCallee
public static boolean requiresCallerOrCallee(DeploymentModel deploymentModel)(Code)



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.