public class HashedAllocationContext extends Object implements AllocationContext
| Modifier and Type | Field and Description |
|---|---|
protected int |
id |
| Modifier | Constructor and Description |
|---|---|
protected |
HashedAllocationContext(int id) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object o)
default implementation is just an identity check
|
AllocationContext |
extend(ClassInfo ci,
int anchor) |
static AllocationContext |
getSUTAllocationContext(ClassInfo ci,
ThreadInfo ti)
this one is for allocations that should depend on the SUT thread context (such as all
explicit NEW executions)
|
static AllocationContext |
getSystemAllocationContext(ClassInfo ci,
ThreadInfo ti,
int anchor)
this one is for allocations that should NOT depend on the SUT thread context (such as
automatic allocation of java.lang.Class objects by the VM)
|
int |
hashCode() |
static boolean |
init(Config conf) |
public static AllocationContext getSUTAllocationContext(ClassInfo ci, ThreadInfo ti)
public static AllocationContext getSystemAllocationContext(ClassInfo ci, ThreadInfo ti, int anchor)
anchor - a value that can be used to provide a context that is heap graph specific (such as
a classloader or class object reference)public static boolean init(Config conf)
public boolean equals(Object o)
Objectpublic AllocationContext extend(ClassInfo ci, int anchor)
extend in interface AllocationContext