Uses of Class
org.apache.bcel.generic.Instruction

Packages that use Instruction
Package
Description
This package contains the "generic" part of the Byte Code Engineering Library, i.e., classes to dynamically modify class objects and byte code instructions.
  • Uses of Instruction in org.apache.bcel.generic

    Modifier and Type
    Class
    Description
    class 
    AALOAD - Load reference from array
    class 
    AASTORE - Store into reference array
    class 
    ACONST_NULL - Push null reference
    class 
    ALOAD - Load reference from local variable
    class 
    ANEWARRAY - Create new array of references
    class 
    ARETURN - Return reference from method
    class 
    Super class for the family of arithmetic instructions.
    class 
    Super class for instructions dealing with array access such as IALOAD.
    class 
    ARRAYLENGTH - Get length of array
    class 
    ASTORE - Store reference into local variable
    class 
    ATHROW - Throw exception
    class 
    BALOAD - Load byte or boolean from array
    class 
    BASTORE - Store into byte or boolean array
    class 
    BIPUSH - Push byte on stack
    class 
    Abstract super class for branching instructions like GOTO, IFEQ, etc..
    class 
    BREAKPOINT, JVM dependent, ignored by default
    class 
    CALOAD - Load char from array
    class 
    CASTORE - Store into char array
    class 
    CHECKCAST - Check whether object is of given type
    class 
    Super class for the x2y family of instructions.
    class 
    Abstract super class for instructions that use an index into the constant pool such as LDC, INVOKEVIRTUAL, etc.
    class 
    D2F - Convert double to float
    class 
    D2I - Convert double to int
    class 
    D2L - Convert double to long
    class 
    DADD - Add doubles
    class 
    DALOAD - Load double from array
    class 
    DASTORE - Store into double array
    class 
    DCMPG - Compare doubles: value1 > value2
    class 
    DCMPL - Compare doubles: value1 < value2
    class 
    DCONST - Push 0.0 or 1.0, other values cause an exception
    class 
    DDIV - Divide doubles
    class 
    DLOAD - Load double from local variable
    class 
    DMUL - Multiply doubles
    class 
    DNEG - Negate double
    class 
    DREM - Remainder of doubles
    class 
    DRETURN - Return double from method
    class 
    DSTORE - Store double into local variable
    class 
    DSUB - Substract doubles
    class 
    DUP - Duplicate top operand stack word
    class 
    DUP_X1 - Duplicate top operand stack word and put two down
    class 
    DUP_X2 - Duplicate top operand stack word and put three down
    class 
    DUP2 - Duplicate two top operand stack words
    class 
    DUP2_X1 - Duplicate two top operand stack words and put three down
    class 
    DUP2_X2 - Duplicate two top operand stack words and put four down
    class 
    F2D - Convert float to double
    class 
    F2I - Convert float to int
    class 
    F2L - Convert float to long
    class 
    FADD - Add floats
    class 
    FALOAD - Load float from array
    class 
    FASTORE - Store into float array
    class 
    FCMPG - Compare floats: value1 > value2
    class 
    FCMPL - Compare floats: value1 < value2
    class 
    FCONST - Push 0.0, 1.0 or 2.0, other values cause an exception
    class 
    FDIV - Divide floats
    class 
    Super class for the GET/PUTxxx family of instructions.
    class 
    Super class for InvokeInstruction and FieldInstruction, since they have some methods in common!
    class 
    FLOAD - Load float from local variable
    class 
    FMUL - Multiply floats
    class 
    FNEG - Negate float
    class 
    FREM - Remainder of floats
    class 
    FRETURN - Return float from method
    class 
    FSTORE - Store float into local variable
    class 
    FSUB - Substract floats
    class 
    GETFIELD - Fetch field from object
    class 
    GETSTATIC - Fetch static field from class
    class 
    GOTO - Branch always (to relative offset, not absolute address)
    class 
    GOTO_W - Branch always (to relative offset, not absolute address)
    class 
    Super class for GOTO
    class 
    I2B - Convert int to byte
    class 
    I2C - Convert int to char
    class 
    I2D - Convert int to double
    class 
    I2F - Convert int to float
    class 
    I2L - Convert int to long
    class 
    I2S - Convert int to short
    class 
    IADD - Add ints
    class 
    IALOAD - Load int from array
    class 
    IAND - Bitwise AND int
    class 
    IASTORE - Store into int array
    class 
    ICONST - Push value between -1, ..., 5, other values cause an exception
    class 
    IDIV - Divide ints
    class 
    IF_ACMPEQ - Branch if reference comparison succeeds
    class 
    IF_ACMPNE - Branch if reference comparison doesn't succeed
    class 
    IF_ICMPEQ - Branch if int comparison succeeds
    class 
    IF_ICMPGE - Branch if int comparison succeeds
    class 
    IF_ICMPGT - Branch if int comparison succeeds
    class 
    IF_ICMPLE - Branch if int comparison succeeds
    class 
    IF_ICMPLT - Branch if int comparison succeeds
    class 
    IF_ICMPNE - Branch if int comparison doesn't succeed
    class 
    IFEQ - Branch if int comparison with zero succeeds
    class 
    IFGE - Branch if int comparison with zero succeeds
    class 
    IFGT - Branch if int comparison with zero succeeds
    class 
    Super class for the IFxxx family of instructions.
    class 
    IFLE - Branch if int comparison with zero succeeds
    class 
    IFLT - Branch if int comparison with zero succeeds
    class 
    IFNE - Branch if int comparison with zero succeeds
    class 
    IFNONNULL - Branch if reference is not null
    class 
    IFNULL - Branch if reference is not null
    class 
    IINC - Increment local variable by constant
    class 
    ILOAD - Load int from local variable onto stack
    class 
    IMPDEP1 - Implementation dependent
    class 
    IMPDEP2 - Implementation dependent
    class 
    IMUL - Multiply ints
    class 
    INEG - Negate int
    class 
    INSTANCEOF - Determine if object is of given type
    class 
    Class for INVOKEDYNAMIC.
    class 
    Super class for the INVOKExxx family of instructions.
    final class 
    INVOKEINTERFACE - Invoke interface method
    class 
    INVOKESPECIAL - Invoke instance method; special handling for superclass, private and instance initialization method invocations
    class 
    INVOKESTATIC - Invoke a class (static) method
    class 
    INVOKEVIRTUAL - Invoke instance method; dispatch based on class
    class 
    IOR - Bitwise OR int
    class 
    IREM - Remainder of int
    class 
    IRETURN - Return int from method
    class 
    ISHL - Arithmetic shift left int
    class 
    ISHR - Arithmetic shift right int
    class 
    ISTORE - Store int from stack into local variable
    class 
    ISUB - Substract ints
    class 
    IUSHR - Logical shift right int
    class 
    IXOR - Bitwise XOR int
    class 
    JSR - Jump to subroutine
    class 
    JSR_W - Jump to subroutine
    class 
    Super class for JSR - Jump to subroutine
    class 
    L2D - Convert long to double
    class 
    L2F - Convert long to float
    class 
    L2I - Convert long to int
    class 
    LADD - Add longs
    class 
    LALOAD - Load long from array
    class 
    LAND - Bitwise AND longs
    class 
    LASTORE - Store into long array
    class 
    LCMP - Compare longs:
    class 
    LCONST - Push 0 or 1, other values cause an exception
    class 
    LDC - Push item from constant pool.
    class 
    LDC_W - Push item from constant pool (wide index)
    class 
    LDC2_W - Push long or double from constant pool
    class 
    LDIV - Divide longs
    class 
    LLOAD - Load long from local variable
    class 
    LMUL - Multiply longs
    class 
    LNEG - Negate long
    class 
    Denotes an unparameterized instruction to load a value from a local variable, e.g.
    class 
    Abstract super class for instructions dealing with local variables.
    class 
    LOOKUPSWITCH - Switch with unordered set of values
    class 
    LOR - Bitwise OR long
    class 
    LREM - Remainder of long
    class 
    LRETURN - Return long from method
    class 
    LSHL - Arithmetic shift left long
    class 
    LSHR - Arithmetic shift right long
    class 
    LSTORE - Store long into local variable
    class 
    LSUB - Substract longs
    class 
    LUSHR - Logical shift right long
    class 
    LXOR - Bitwise XOR long
    class 
    MONITORENTER - Enter monitor for object
    class 
    MONITOREXIT - Exit monitor for object
    class 
    MULTIANEWARRAY - Create new mutidimensional array of references
    class 
    Super class for FieldOrMethod and INVOKEDYNAMIC, since they both have names and signatures
    class 
    NEW - Create new object
    class 
    NEWARRAY - Create new array of basic type (int, short, ...)
    class 
    NOP - Do nothing
    class 
    POP - Pop top operand stack word
    class 
    POP2 - Pop two top operand stack words
    class 
    PUTFIELD - Put field in object
    class 
    PUTSTATIC - Put static field in class
    class 
    RET - Return from subroutine
    class 
    RETURN - Return from void method
    class 
    Super class for the xRETURN family of instructions.
    class 
    SALOAD - Load short from array
    class 
    SASTORE - Store into short array
    class 
    Select - Abstract super class for LOOKUPSWITCH and TABLESWITCH instructions.
    class 
    SIPUSH - Push short
    class 
    Super class for stack operations like DUP and POP.
    class 
    Denotes an unparameterized instruction to store a value into a local variable, e.g.
    class 
    SWAP - Swa top operand stack word
    class 
    TABLESWITCH - Switch within given range of values, i.e., low..high
    Fields in org.apache.bcel.generic declared as Instruction
    Modifier and Type
    Field
    Description
    static final Instruction
    InstructionConst.ACONST_NULL
     
    static final Instruction
    InstructionConstants.ACONST_NULL
    Deprecated.
     
    static final Instruction
    InstructionConst.ARRAYLENGTH
     
    static final Instruction
    InstructionConstants.ARRAYLENGTH
    Deprecated.
     
    static final Instruction
    InstructionConst.ATHROW
     
    static final Instruction
    InstructionConstants.ATHROW
    Deprecated.
     
    static final Instruction
    InstructionConst.DCMPG
     
    static final Instruction
    InstructionConstants.DCMPG
    Deprecated.
     
    static final Instruction
    InstructionConst.DCMPL
     
    static final Instruction
    InstructionConstants.DCMPL
    Deprecated.
     
    static final Instruction
    InstructionConst.DCONST_0
     
    static final Instruction
    InstructionConstants.DCONST_0
    Deprecated.
     
    static final Instruction
    InstructionConst.DCONST_1
     
    static final Instruction
    InstructionConstants.DCONST_1
    Deprecated.
     
    static final Instruction
    InstructionConst.FCMPG
     
    static final Instruction
    InstructionConstants.FCMPG
    Deprecated.
     
    static final Instruction
    InstructionConst.FCMPL
     
    static final Instruction
    InstructionConstants.FCMPL
    Deprecated.
     
    static final Instruction
    InstructionConst.FCONST_0
     
    static final Instruction
    InstructionConstants.FCONST_0
    Deprecated.
     
    static final Instruction
    InstructionConst.FCONST_1
     
    static final Instruction
    InstructionConstants.FCONST_1
    Deprecated.
     
    static final Instruction
    InstructionConst.FCONST_2
     
    static final Instruction
    InstructionConstants.FCONST_2
    Deprecated.
     
    static final Instruction
    InstructionConst.ICONST_0
     
    static final Instruction
    InstructionConstants.ICONST_0
    Deprecated.
     
    static final Instruction
    InstructionConst.ICONST_1
     
    static final Instruction
    InstructionConstants.ICONST_1
    Deprecated.
     
    static final Instruction
    InstructionConst.ICONST_2
     
    static final Instruction
    InstructionConstants.ICONST_2
    Deprecated.
     
    static final Instruction
    InstructionConst.ICONST_3
     
    static final Instruction
    InstructionConstants.ICONST_3
    Deprecated.
     
    static final Instruction
    InstructionConst.ICONST_4
     
    static final Instruction
    InstructionConstants.ICONST_4
    Deprecated.
     
    static final Instruction
    InstructionConst.ICONST_5
     
    static final Instruction
    InstructionConstants.ICONST_5
    Deprecated.
     
    static final Instruction
    InstructionConst.ICONST_M1
     
    static final Instruction
    InstructionConstants.ICONST_M1
    Deprecated.
     
    static final Instruction[]
    InstructionConstants.INSTRUCTIONS
    Deprecated.
    Get object via its opcode, for immutable instructions like branch instructions entries are set to null.
    static final Instruction
    InstructionConst.LCMP
     
    static final Instruction
    InstructionConstants.LCMP
    Deprecated.
     
    static final Instruction
    InstructionConst.LCONST_0
     
    static final Instruction
    InstructionConstants.LCONST_0
    Deprecated.
     
    static final Instruction
    InstructionConst.LCONST_1
     
    static final Instruction
    InstructionConstants.LCONST_1
    Deprecated.
     
    static final Instruction
    InstructionConst.MONITORENTER
     
    static final Instruction
    InstructionConstants.MONITORENTER
    Deprecated.
     
    static final Instruction
    InstructionConst.MONITOREXIT
     
    static final Instruction
    InstructionConstants.MONITOREXIT
    Deprecated.
     
    static final Instruction
    InstructionConst.NOP
    Predefined instruction objects
    static final Instruction
    InstructionConstants.NOP
    Deprecated.
    Predefined instruction objects
    Methods in org.apache.bcel.generic that return Instruction
    Modifier and Type
    Method
    Description
    Instruction.copy()
    Use with caution, since `BranchInstruction's have a `target' reference which is not copied correctly (only basic types are).
    InstructionFactory.createAppend(Type type)
     
    InstructionFactory.createCast(Type src_type, Type dest_type)
    Create conversion operation for two stack operands, this may be an I2C, instruction, e.g., if the operands are basic types and CHECKCAST if they are reference types.
    InstructionFactory.createConstant(Object value)
    Uses PUSH to push a constant value onto the stack.
    InstructionFactory.createNewArray(Type t, short dim)
    Create new array of given size and type.
    InstructionFactory.createNull(Type type)
    Create "null" value for reference types, 0 for basic types like int
    InstructionFactory.createThis()
    Create reference to `this'
    InstructionConst.getInstruction(int index)
    Gets the Instruction.
    InstructionHandle.getInstruction()
     
     
     
    InstructionList.getInstructions()
     
    Instruction.readInstruction(ByteSequence bytes)
    Read an instruction from (byte code) input stream and return the appropiate object.
    InstructionHandle.swapInstruction(Instruction i)
    Temporarily swap the current instruction, without disturbing anything.
    Methods in org.apache.bcel.generic with parameters of type Instruction
    Modifier and Type
    Method
    Description
    InstructionList.append(Instruction i)
    Append an instruction to the end of this list.
    InstructionList.append(InstructionHandle ih, Instruction i)
    Append an instruction after instruction (handle) ih contained in this list.
    InstructionList.append(Instruction i, CompoundInstruction c)
    Append a compound instruction, after instruction i.
    InstructionList.append(Instruction i, Instruction j)
    Append a single instruction j after another instruction i, which must be in this list of course!
    InstructionList.append(Instruction i, InstructionList il)
    Append another list after instruction i contained in this list.
    boolean
    InstructionList.contains(Instruction i)
     
    void
    InstructionList.delete(Instruction i)
    Remove instruction from this list.
    void
    InstructionList.delete(Instruction from, Instruction to)
    Remove instructions from instruction `from' to instruction `to' contained in this list.
    boolean
    InstructionComparator.equals(Instruction i1, Instruction i2)
     
    InstructionList.insert(Instruction i)
    Insert an instruction at start of this list.
    InstructionList.insert(InstructionHandle ih, Instruction i)
    Insert an instruction before instruction (handle) ih contained in this list.
    InstructionList.insert(Instruction i, CompoundInstruction c)
    Insert a compound instruction before instruction i.
    InstructionList.insert(Instruction i, Instruction j)
    Insert a single instruction j before another instruction i, which must be in this list of course!
    InstructionList.insert(Instruction i, InstructionList il)
    Insert another list before Instruction i contained in this list.
    void
    BranchHandle.setInstruction(Instruction i)
    Set new contents.
    void
    InstructionHandle.setInstruction(Instruction i)
    Replace current instruction contained in this handle.
    InstructionHandle.swapInstruction(Instruction i)
    Temporarily swap the current instruction, without disturbing anything.
    Constructors in org.apache.bcel.generic with parameters of type Instruction
    Modifier
    Constructor
    Description
    protected
     
     
    Create instruction list containing one instruction.