Class SimpleStmtPositionInfo

java.lang.Object
sootup.core.jimple.basic.StmtPositionInfo
sootup.core.jimple.basic.SimpleStmtPositionInfo
Direct Known Subclasses:
FullStmtPositionInfo

public class SimpleStmtPositionInfo extends StmtPositionInfo
This class stores position information (the line number + first/last column) stored for a statement.
Author:
Markus Schmidt
  • Field Details

    • stmtPosition

      protected final @NonNull Position stmtPosition
  • Constructor Details

    • SimpleStmtPositionInfo

      public SimpleStmtPositionInfo(@NonNull Position stmtPosition)
    • SimpleStmtPositionInfo

      public SimpleStmtPositionInfo(int lineNumber)
      Create an instance only from line number, this is usually the case from byte code front-end.
      Parameters:
      lineNumber - the line number of the statement.
  • Method Details

    • getStmtPosition

      public @NonNull Position getStmtPosition()
      Description copied from class: StmtPositionInfo
      Return the position of the statement.
      Specified by:
      getStmtPosition in class StmtPositionInfo
      Returns:
      the position of the statement
    • getOperandPosition

      public @Nullable Position getOperandPosition(int index)
      Description copied from class: StmtPositionInfo
      Return the precise position of the given operand in the statement.
      Specified by:
      getOperandPosition in class StmtPositionInfo
      Parameters:
      index - the operand index
      Returns:
      the position of the given operand