com.android.dx.cf.code
Class ByteCatchList.Item

java.lang.Object
  extended by com.android.dx.cf.code.ByteCatchList.Item
Enclosing class:
ByteCatchList

public static class ByteCatchList.Item
extends Object

Item in an exception handler list.


Constructor Summary
ByteCatchList.Item(int startPc, int endPc, int handlerPc, CstType exceptionClass)
          Constructs an instance.
 
Method Summary
 boolean covers(int pc)
          Returns whether the given address is in the range of this item.
 int getEndPc()
          Gets the end pc (exclusive) of the handler's range.
 CstType getExceptionClass()
          Gets the class of exception handled.
 int getHandlerPc()
          Gets the pc of the exception handler.
 int getStartPc()
          Gets the start pc (inclusive) of the handler's range.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ByteCatchList.Item

public ByteCatchList.Item(int startPc,
                          int endPc,
                          int handlerPc,
                          CstType exceptionClass)
Constructs an instance.

Parameters:
startPc - >= 0; the start pc (inclusive) of the handler's range
endPc - >= startPc; the end pc (exclusive) of the handler's range
handlerPc - >= 0; the pc of the exception handler
exceptionClass - null-ok; the exception class or null to catch all exceptions with this handler
Method Detail

getStartPc

public int getStartPc()
Gets the start pc (inclusive) of the handler's range.

Returns:
>= 0; the start pc (inclusive) of the handler's range.

getEndPc

public int getEndPc()
Gets the end pc (exclusive) of the handler's range.

Returns:
>= startPc; the end pc (exclusive) of the handler's range.

getHandlerPc

public int getHandlerPc()
Gets the pc of the exception handler.

Returns:
>= 0; the pc of the exception handler

getExceptionClass

public CstType getExceptionClass()
Gets the class of exception handled.

Returns:
non-null; the exception class; CstType.OBJECT if this entry handles all possible exceptions

covers

public boolean covers(int pc)
Returns whether the given address is in the range of this item.

Parameters:
pc - the address
Returns:
true iff this item covers pc


Copyright © 2015. All rights reserved.