|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.drools.util.asm.MethodComparator
public class MethodComparator
The purpose of this utility it to check if 2 method implementations are equivalent, by comparing the bytecode. This essentual for node sharing where java semantics are involved.
| Nested Class Summary | |
|---|---|
static class |
MethodComparator.Tracer
|
| Constructor Summary | |
|---|---|
MethodComparator()
|
|
| Method Summary | |
|---|---|
static boolean |
compareBytecode(List b1,
List b2)
Compares 2 bytecode listings. |
boolean |
equivalent(String method1,
ClassReader class1,
String method2,
ClassReader class2)
This actually does the comparing. |
static List |
getMethodBytecode(String methodName,
byte[] bytes)
This will return a series of bytecode instructions which can be used to compare one method with another. |
List |
getMethodBytecode(String methodName,
ClassReader classReader)
This will return a series of bytecode instructions which can be used to compare one method with another. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MethodComparator()
| Method Detail |
|---|
public boolean equivalent(String method1, ClassReader class1, String method2, ClassReader class2)
public List getMethodBytecode(String methodName, ClassReader classReader)
public static List getMethodBytecode(String methodName, byte[] bytes)
public static boolean compareBytecode(List b1, List b2)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||