Class ExceptionTableEntry


  • public class ExceptionTableEntry
    extends Object
    Represents an entry in the exception table of a Code attribute.
    • Constructor Detail

      • ExceptionTableEntry

        public ExceptionTableEntry​(int startPc,
                                   int endPc,
                                   int handlerPc,
                                   int catchType)
        Constructs an exception table entry.
        Parameters:
        startPc - start of the try block (inclusive)
        endPc - end of the try block (exclusive)
        handlerPc - start of the exception handler
        catchType - constant pool index of the exception class, or 0 for any
    • Method Detail

      • getStartPc

        public int getStartPc()
        Returns:
        the inclusive start program counter of the try block
      • setStartPc

        public void setStartPc​(int startPc)
        Parameters:
        startPc - the new inclusive start program counter
      • getEndPc

        public int getEndPc()
        Returns:
        the exclusive end program counter of the try block
      • setEndPc

        public void setEndPc​(int endPc)
        Parameters:
        endPc - the new exclusive end program counter
      • getHandlerPc

        public int getHandlerPc()
        Returns:
        the handler program counter
      • setHandlerPc

        public void setHandlerPc​(int handlerPc)
        Parameters:
        handlerPc - the new handler program counter
      • getCatchType

        public int getCatchType()
        Returns:
        the catch type index, or 0 for any exception