public interface

IDexDebugInfo

com.pnfsoftware.jeb.core.units.code.android.dex.IDexDebugInfo

Class Overview

This interface represents Dex debug information for a method. Debug information can be forged and should not be trusted.

This interface offers a medium-level and high-level view of debug information available for a given method:
- medium-level: use getVariables(int) and getLineInfo(int)
- high-level (most clients will want to use that): use getKnownVariablesMap(IDexMethod)

Summary

Constants
int DBG_ADVANCE_LINE
int DBG_ADVANCE_PC
int DBG_END_LOCAL
int DBG_END_SEQUENCE
int DBG_FIRST_SPECIAL
int DBG_LINE_BASE
int DBG_LINE_RANGE
int DBG_RESTART_LOCAL
int DBG_SET_EPILOGUE_BEGIN
int DBG_SET_FILE
int DBG_SET_PROLOGUE_END
int DBG_START_LOCAL
int DBG_START_LOCAL_EXTENDED
Public Methods
abstract SortedMap<Integer, List<IDexDebugVariable>> getKnownVariablesMap(IDexMethod m)
Retrieve a map of variables defined at a given instruction point.
abstract IDexDebugLine getLineInfo(int address)
Get the information for the line of code associated with a given bytecode address.
abstract int[] getParameterNameIndexes()
Get the name indexes for the parameters of the method.
abstract List<IDexDebugVariable> getVariables(int address)

Constants

public static final int DBG_ADVANCE_LINE

Constant Value: 2 (0x00000002)

public static final int DBG_ADVANCE_PC

Constant Value: 1 (0x00000001)

public static final int DBG_END_LOCAL

Constant Value: 5 (0x00000005)

public static final int DBG_END_SEQUENCE

Constant Value: 0 (0x00000000)

public static final int DBG_FIRST_SPECIAL

Constant Value: 10 (0x0000000a)

public static final int DBG_LINE_BASE

Constant Value: -4 (0xfffffffc)

public static final int DBG_LINE_RANGE

Constant Value: 15 (0x0000000f)

public static final int DBG_RESTART_LOCAL

Constant Value: 6 (0x00000006)

public static final int DBG_SET_EPILOGUE_BEGIN

Constant Value: 8 (0x00000008)

public static final int DBG_SET_FILE

Constant Value: 9 (0x00000009)

public static final int DBG_SET_PROLOGUE_END

Constant Value: 7 (0x00000007)

public static final int DBG_START_LOCAL

Constant Value: 3 (0x00000003)

public static final int DBG_START_LOCAL_EXTENDED

Constant Value: 4 (0x00000004)

Public Methods

public abstract SortedMap<Integer, List<IDexDebugVariable>> getKnownVariablesMap (IDexMethod m)

Retrieve a map of variables defined at a given instruction point.

Returns
  • on error, an empty map; else a map of: key= method offset (in bytes); value= list of all debug variables existing (having a definition) at that instruction

public abstract IDexDebugLine getLineInfo (int address)

Get the information for the line of code associated with a given bytecode address.

Parameters
address offset in method in 16-bit code units
Returns
  • the line information object, null if none

public abstract int[] getParameterNameIndexes ()

Get the name indexes for the parameters of the method.

Returns
  • the list of name indexes, or null if none

public abstract List<IDexDebugVariable> getVariables (int address)

Parameters
address offset in method in 16-bit code units
Returns
  • a list of variables, possibly empty