jasco.runtime.connector
Class MethodSignature

java.lang.Object
  extended by jasco.runtime.connector.MethodSignature
All Implemented Interfaces:
ISignatureMatcher

public class MethodSignature
extends java.lang.Object
implements ISignatureMatcher

class that represents the method signature defined in a connector. Is bound to exactly one abstract method parameter of a hook's constructor. See CombinedMethodSignature for multiple bindings.

Author:
Wim

Field Summary
static int ALL_SUBTYPES
           
static int IMPL_SUBTYPES
           
static int NO_SUBTYPES
           
 
Constructor Summary
MethodSignature(java.lang.String returnType, java.lang.String type, java.lang.String methodname)
           
 
Method Summary
protected  void addAnnotation(java.lang.String annotation)
           
protected  void addArgument(java.lang.String argument)
           
static MethodSignature build(java.lang.String returnType, java.lang.String type, java.lang.String methodName, java.lang.String[] arguments, java.lang.String[] annotations, int matchSubtypes)
           
protected  boolean equals(MethodJoinpoint jp, javassist.CtMethod method)
           
 java.util.Iterator getAnnotations()
           
 java.util.Iterator getArguments()
           
 int getMatchSubTypes()
           
 java.lang.String getMethodname()
           
 java.lang.String getReturnType()
           
 java.util.Iterator getSignatures()
           
 java.lang.String getType()
           
 java.lang.String getVariableString()
           
 java.lang.String getVariableString(MethodJoinpoint jp)
           
 boolean matchesClass(java.lang.String clzName)
           
 boolean matchesClass(java.lang.String clzName, java.lang.ClassLoader classLoader)
           
 boolean matchesClass(java.lang.String clzName, javassist.ClassPool pool)
           
 boolean matchesJoinpoint(MethodJoinpoint jp)
           
protected  void setMatchSubTypes(int matchSubTypes)
           
protected  void setMethodname(java.lang.String methodname)
           
protected  void setReturnType(java.lang.String returnType)
           
protected  void setType(java.lang.String type)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

NO_SUBTYPES

public static final int NO_SUBTYPES
See Also:
Constant Field Values

IMPL_SUBTYPES

public static final int IMPL_SUBTYPES
See Also:
Constant Field Values

ALL_SUBTYPES

public static final int ALL_SUBTYPES
See Also:
Constant Field Values
Constructor Detail

MethodSignature

public MethodSignature(java.lang.String returnType,
                       java.lang.String type,
                       java.lang.String methodname)
Method Detail

matchesJoinpoint

public boolean matchesJoinpoint(MethodJoinpoint jp)
Specified by:
matchesJoinpoint in interface ISignatureMatcher

equals

protected boolean equals(MethodJoinpoint jp,
                         javassist.CtMethod method)

matchesClass

public boolean matchesClass(java.lang.String clzName,
                            java.lang.ClassLoader classLoader)
Specified by:
matchesClass in interface ISignatureMatcher

matchesClass

public boolean matchesClass(java.lang.String clzName)
Specified by:
matchesClass in interface ISignatureMatcher

matchesClass

public boolean matchesClass(java.lang.String clzName,
                            javassist.ClassPool pool)
Specified by:
matchesClass in interface ISignatureMatcher

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

getVariableString

public java.lang.String getVariableString()

getVariableString

public java.lang.String getVariableString(MethodJoinpoint jp)

getAnnotations

public java.util.Iterator getAnnotations()

getArguments

public java.util.Iterator getArguments()

addAnnotation

protected void addAnnotation(java.lang.String annotation)

addArgument

protected void addArgument(java.lang.String argument)

getMatchSubTypes

public int getMatchSubTypes()
Returns:
Returns the matchSubTypes.

setMatchSubTypes

protected void setMatchSubTypes(int matchSubTypes)
Parameters:
matchSubTypes - The matchSubTypes to set.

getMethodname

public java.lang.String getMethodname()
Returns:
Returns the methodname.

setMethodname

protected void setMethodname(java.lang.String methodname)
Parameters:
methodname - The methodname to set.

getReturnType

public java.lang.String getReturnType()
Returns:
Returns the returnType.

setReturnType

protected void setReturnType(java.lang.String returnType)
Parameters:
returnType - The returnType to set.

getType

public java.lang.String getType()
Returns:
Returns the type.

setType

protected void setType(java.lang.String type)
Parameters:
type - The type to set.

build

public static MethodSignature build(java.lang.String returnType,
                                    java.lang.String type,
                                    java.lang.String methodName,
                                    java.lang.String[] arguments,
                                    java.lang.String[] annotations,
                                    int matchSubtypes)

getSignatures

public java.util.Iterator getSignatures()
Specified by:
getSignatures in interface ISignatureMatcher