public class CompositeHeapJvmAbstractState extends AbstractWrapperState implements LatticeAbstractState<CompositeHeapJvmAbstractState>, ProgramLocationDependent<JvmCfaNode,JvmCfaEdge,MethodSignature>
AbstractWrapperState stores a JvmReferenceAbstractState having the JvmTreeHeapPrincipalAbstractState
and a sequence of JvmAbstractStates which may have JvmTreeHeapFollowerAbstractStates depending on the first abstract state. Join and copy are done elementwise
preserving the link between the heap models.
The composite abstract state must have the JvmReferenceAbstractState at its REFERENCE_STATE_INDEXth position. This abstract state will be used as the principal heap model
for other abstract states.
| Modifier and Type | Field and Description |
|---|---|
static int |
REFERENCE_STATE_INDEX |
| Constructor and Description |
|---|
CompositeHeapJvmAbstractState(java.util.List<JvmAbstractState<? extends LatticeAbstractState<? extends AbstractState>>> jvmAbstractStates)
Create a composite abstract state from a list of JVM abstract states.
|
| Modifier and Type | Method and Description |
|---|---|
AbstractState |
copy()
Creates a copy of itself.
|
JvmCfaNode |
getProgramLocation()
Returns the program location.
|
JvmAbstractState<? extends LatticeAbstractState<? extends AbstractState>> |
getStateByIndex(int index)
Returns the state at the specified position in the composite state.
|
AbstractState |
getStateByName(java.lang.String name)
Returns an abstract state for a given if the state is composite, returns
self otherwise. |
java.util.List<JvmAbstractState<? extends LatticeAbstractState<? extends AbstractState>>> |
getWrappedStates()
Returns the wrapped abstract states.
|
boolean |
isLessOrEqual(CompositeHeapJvmAbstractState abstractState)
Compares itself to the
abstractState. |
CompositeHeapJvmAbstractState |
join(CompositeHeapJvmAbstractState abstractState)
Computes a join over itself and the
abstractState. |
void |
setProgramLocation(JvmCfaNode programLocation)
Sets the program location.
|
void |
updateHeapDependence() |
equals, hashCodeclone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitisLessequals, getPrecision, hashCodepublic static final int REFERENCE_STATE_INDEX
public CompositeHeapJvmAbstractState(java.util.List<JvmAbstractState<? extends LatticeAbstractState<? extends AbstractState>>> jvmAbstractStates)
jvmAbstractStates - a list of JvmAbstractStates, must contain a JvmReferenceAbstractState at its REFERENCE_INDEXth positionpublic JvmAbstractState<? extends LatticeAbstractState<? extends AbstractState>> getStateByIndex(int index)
public void updateHeapDependence()
public java.util.List<JvmAbstractState<? extends LatticeAbstractState<? extends AbstractState>>> getWrappedStates()
AbstractWrapperStategetWrappedStates in class AbstractWrapperStatepublic CompositeHeapJvmAbstractState join(CompositeHeapJvmAbstractState abstractState)
LatticeAbstractStateabstractState.join in interface LatticeAbstractState<CompositeHeapJvmAbstractState>public boolean isLessOrEqual(CompositeHeapJvmAbstractState abstractState)
LatticeAbstractStateabstractState.isLessOrEqual in interface LatticeAbstractState<CompositeHeapJvmAbstractState>public JvmCfaNode getProgramLocation()
ProgramLocationDependentgetProgramLocation in interface ProgramLocationDependent<JvmCfaNode,JvmCfaEdge,MethodSignature>public void setProgramLocation(JvmCfaNode programLocation)
ProgramLocationDependentsetProgramLocation in interface ProgramLocationDependent<JvmCfaNode,JvmCfaEdge,MethodSignature>public AbstractState getStateByName(java.lang.String name)
AbstractStateself otherwise.getStateByName in interface AbstractStatepublic AbstractState copy()
AbstractStatecopy in interface AbstractState