com.android.dx.dex.code
Class CatchTable

java.lang.Object
  extended by com.android.dx.util.MutabilityControl
      extended by com.android.dx.util.FixedSizeList
          extended by com.android.dx.dex.code.CatchTable
All Implemented Interfaces:
ToHuman, Comparable<CatchTable>

public final class CatchTable
extends FixedSizeList
implements Comparable<CatchTable>

Table of catch entries. Each entry includes a range of code addresses for which it is valid and an associated CatchHandlerList.


Nested Class Summary
static class CatchTable.Entry
          Entry in a catch list.
 
Field Summary
static CatchTable EMPTY
          non-null; empty instance
 
Constructor Summary
CatchTable(int size)
          Constructs an instance.
 
Method Summary
 int compareTo(CatchTable other)
          
 CatchTable.Entry get(int n)
          Gets the element at the given index.
 void set(int n, CatchTable.Entry entry)
          Sets the entry at the given index.
 
Methods inherited from class com.android.dx.util.FixedSizeList
equals, get0, getOrNull0, hashCode, set0, shrinkToFit, size, toHuman, toHuman, toString, toString
 
Methods inherited from class com.android.dx.util.MutabilityControl
isImmutable, isMutable, setImmutable, throwIfImmutable, throwIfMutable
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

EMPTY

public static final CatchTable EMPTY
non-null; empty instance

Constructor Detail

CatchTable

public CatchTable(int size)
Constructs an instance. All indices initially contain null.

Parameters:
size - >= 0; the size of the table
Method Detail

get

public CatchTable.Entry get(int n)
Gets the element at the given index. It is an error to call this with the index for an element which was never set; if you do that, this will throw NullPointerException.

Parameters:
n - >= 0, < size(); which index
Returns:
non-null; element at that index

set

public void set(int n,
                CatchTable.Entry entry)
Sets the entry at the given index.

Parameters:
n - >= 0, < size(); which index
entry - non-null; the entry to set at n

compareTo

public int compareTo(CatchTable other)

Specified by:
compareTo in interface Comparable<CatchTable>


Copyright © 2013. All Rights Reserved.