org.codehaus.aspectwerkz.transform
Class TransformationUtil

java.lang.Object
  extended byorg.codehaus.aspectwerkz.transform.TransformationUtil

public final class TransformationUtil
extends Object

Utility method used by the transformers.

Author:
Jonas Bonér

Constructor Summary
TransformationUtil()
           
 
Method Summary
static String getConstructorBodyMethodName(String calleeTypeName)
          Returns the method name used for constructor body
static String getConstructorBodyMethodSignature(String ctorDesc, String calleeTypeName)
          Returns the method used for constructor body signature The callee type name is prepended to the constructor signature
static String getInvokeSignatureForCodeJoinPoints(int codeModifiers, String codeDesc, String callerTypeName, String calleeTypeName)
          Build the join point invoke method descriptor for code (method or constructor) join points.
static String getInvokeSignatureForFieldJoinPoints(int fieldModifiers, String fieldDesc, String callerTypeName, String calleeTypeName)
          Build the join point invoke method descriptor for field join points.
static String getPrefixedOriginalMethodName(String methodName, int methodSequence, String className)
          Returns the prefixed method name.
static String getWrapperMethodName(String methodName, int methodSequence, String className, String prefix)
          Returns the prefixed method name.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TransformationUtil

public TransformationUtil()
Method Detail

getPrefixedOriginalMethodName

public static String getPrefixedOriginalMethodName(String methodName,
                                                   int methodSequence,
                                                   String className)
Returns the prefixed method name.

Parameters:
methodName - the method name
methodSequence - the method sequence
className - the class name
Returns:
the name of the join point

getWrapperMethodName

public static String getWrapperMethodName(String methodName,
                                          int methodSequence,
                                          String className,
                                          String prefix)
Returns the prefixed method name.

Parameters:
methodName - the method name
methodSequence - the method sequence
className - the class name
Returns:
the name of the join point

getInvokeSignatureForCodeJoinPoints

public static String getInvokeSignatureForCodeJoinPoints(int codeModifiers,
                                                         String codeDesc,
                                                         String callerTypeName,
                                                         String calleeTypeName)
Build the join point invoke method descriptor for code (method or constructor) join points. Depends if the target method is static or not.

Parameters:
codeModifiers -
codeDesc -
callerTypeName -
calleeTypeName -
Returns:

getInvokeSignatureForFieldJoinPoints

public static String getInvokeSignatureForFieldJoinPoints(int fieldModifiers,
                                                          String fieldDesc,
                                                          String callerTypeName,
                                                          String calleeTypeName)
Build the join point invoke method descriptor for field join points. Depends if the target field is static or not.

Parameters:
fieldModifiers -
fieldDesc -
callerTypeName -
calleeTypeName -
Returns:

getConstructorBodyMethodName

public static String getConstructorBodyMethodName(String calleeTypeName)
Returns the method name used for constructor body

Parameters:
calleeTypeName -
Returns:

getConstructorBodyMethodSignature

public static String getConstructorBodyMethodSignature(String ctorDesc,
                                                       String calleeTypeName)
Returns the method used for constructor body signature The callee type name is prepended to the constructor signature

Parameters:
ctorDesc -
calleeTypeName -
Returns:


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