Package jadex.bdi.model
Class NodeHelper
java.lang.Object
jadex.bdi.model.NodeHelper
- Direct Known Subclasses:
AsmNodeHelper
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract org.objectweb.asm.tree.FieldNode
createField
(int access, String name, String desc, String[] signature, Object initialValue) abstract org.objectweb.asm.tree.MethodNode
createReturnConstantMethod
(String methodName, int value) Creates a Method that always returns the given value.static NodeHelper
int
getLineNumberOfMethod
(org.objectweb.asm.tree.MethodNode mn) Returns the line number of the first LineNumberNode in the instructions of the given MethodNode, or -1, if none found.
-
Constructor Details
-
NodeHelper
public NodeHelper()
-
-
Method Details
-
getInstance
-
getLineNumberOfMethod
public int getLineNumberOfMethod(org.objectweb.asm.tree.MethodNode mn) Returns the line number of the first LineNumberNode in the instructions of the given MethodNode, or -1, if none found.- Parameters:
mn
- The MethodNode to look into- Returns:
- the line number or -1, if none found
-
createReturnConstantMethod
public abstract org.objectweb.asm.tree.MethodNode createReturnConstantMethod(String methodName, int value) Creates a Method that always returns the given value.- Parameters:
methodName
-value
-- Returns:
- the new method
-
createField
-