org.apache.bcel.verifier.structurals

## Interface InstructionContext

-     public interface InstructionContext

  An InstructionContext offers convenient access to information like control flow successors and such.
  Version:
    $Id: InstructionContext.java 1806200 2017-08-25 16:33:06Z ggregory $

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `execute(Frame inFrame, ArrayList<InstructionContext> executionPredecessors, InstConstraintVisitor icv, ExecutionVisitor ev)` This method symbolically executes the Instruction held in the InstructionContext.
    `ExceptionHandler[]` | `getExceptionHandlers()` Returns the exception handlers that protect this instruction.
    `Frame` | `getInFrame()`
    `InstructionHandle` | `getInstruction()` Returns the InstructionHandle this InstructionContext is wrapped around.
    `Frame` | `getOutFrame(ArrayList<InstructionContext> executionPredecessors)` This method returns the outgoing execution frame situation; therefore it has to be calculated by execute(Frame, ArrayList) first.
    `InstructionContext[]` | `getSuccessors()` Returns the usual control flow successors.
    `int` | `getTag()` The getTag and setTag methods may be used for temporary flagging, such as graph colouring.
    `void` | `setTag(int tag)` The getTag and setTag methods may be used for temporary flagging, such as graph colouring.

- - ### Method Detail

    - #### getTag

          int getTag()

      The getTag and setTag methods may be used for temporary flagging, such as graph colouring. Nothing in the InstructionContext object depends on the value of the tag. JustIce does not use it.
      See Also:
        `setTag(int tag)`

    - #### setTag

          void setTag(int tag)

      The getTag and setTag methods may be used for temporary flagging, such as graph colouring. Nothing in the InstructionContext object depends on the value of the tag. JustIce does not use it.
      See Also:
        `getTag()`

    - #### execute

          boolean execute(Frame inFrame,
                          ArrayList<InstructionContext> executionPredecessors,
                          InstConstraintVisitor icv,
                          ExecutionVisitor ev)

      This method symbolically executes the Instruction held in the InstructionContext. It "merges in" the incoming execution frame situation (see The Java Virtual Machine Specification, 2nd edition, page 146). By so doing, the outgoing execution frame situation is calculated. This method is JustIce-specific and is usually of no sense for users of the ControlFlowGraph class. They should use getInstruction().accept(Visitor), possibly in conjunction with the ExecutionVisitor.
      Returns:
        true - if and only if the "outgoing" frame situation changed from the one before execute()ing.
      See Also:
        `ControlFlowGraph`, `ExecutionVisitor`, `getOutFrame(ArrayList)`

    - #### getInFrame

          Frame getInFrame()

    - #### getOutFrame

          Frame getOutFrame(ArrayList<InstructionContext> executionPredecessors)

      This method returns the outgoing execution frame situation; therefore it has to be calculated by execute(Frame, ArrayList) first.
      See Also:
        `execute(Frame, ArrayList, InstConstraintVisitor, ExecutionVisitor)`

    - #### getInstruction

          InstructionHandle getInstruction()

      Returns the InstructionHandle this InstructionContext is wrapped around.
      Returns:
        The InstructionHandle this InstructionContext is wrapped around.

    - #### getSuccessors

          InstructionContext[] getSuccessors()

      Returns the usual control flow successors.
      See Also:
        `getExceptionHandlers()`

    - #### getExceptionHandlers

          ExceptionHandler[] getExceptionHandlers()

      Returns the exception handlers that protect this instruction. They are special control flow successors.

Copyright © 2004–2017 The Apache Software Foundation. All rights reserved.