public class NullnessStore extends InitializationStore<NullnessValue,NullnessStore> implements org.plumelib.util.UniqueId
InitializationStore
, but additionally tracks whether PolyNull
is
known to be NonNull
or Nullable
(or not known to be either).Store.FlowRule, Store.Kind
Modifier and Type | Field and Description |
---|---|
protected boolean |
isPolyNullNonNull
|
protected boolean |
isPolyNullNull
|
initializedFields, invariantFields
analysis, arrayValues, classValues, fieldValues, localVariableValues, methodValues, sequentialSemantics, thisValue
Constructor and Description |
---|
NullnessStore(CFAbstractAnalysis<NullnessValue,NullnessStore,?> analysis,
boolean sequentialSemantics)
Create a NullnessStore.
|
NullnessStore(NullnessStore s)
Create a NullnessStore (copy constructor).
|
Modifier and Type | Method and Description |
---|---|
long |
getUid()
Returns the unique ID of this object.
|
protected String |
internalVisualize(CFGVisualizer<NullnessValue,NullnessStore,?> viz)
Adds a representation of the internal information of this Store to visualizer
viz . |
boolean |
isPolyNullNonNull()
|
boolean |
isPolyNullNull()
|
NullnessStore |
leastUpperBound(NullnessStore other)
Compute the least upper bound of two stores.
|
void |
setPolyNullNonNull(boolean isPolyNullNonNull)
|
void |
setPolyNullNull(boolean isPolyNullNull)
|
protected boolean |
supersetOf(CFAbstractStore<NullnessValue,NullnessStore> o)
Returns true iff this
CFAbstractStore contains a superset of the map entries of the
argument CFAbstractStore . |
addInitializedField, addInitializedField, getAnalysis, insertValue, isFieldInitialized, updateForMethodCall
canAlias, canInsertReceiver, clearValue, copy, equals, getValue, getValue, getValue, getValue, getValue, getValue, hashCode, initializeMethodParameter, initializeThisValue, insertOrRefine, insertThisValue, insertValue, isMonotonicUpdate, isSideEffectFree, removeConflicting, removeConflicting, removeConflicting, replaceValue, toString, updateForArrayAssignment, updateForAssignment, updateForFieldAccessAssignment, updateForLocalVariableAssignment, visualize, widenedUpperBound
protected boolean isPolyNullNonNull
protected boolean isPolyNullNull
public NullnessStore(CFAbstractAnalysis<NullnessValue,NullnessStore,?> analysis, boolean sequentialSemantics)
analysis
- the analysis class this store belongs tosequentialSemantics
- should the analysis use sequential Java semantics (i.e., assume
that only one thread is running at all times)?public NullnessStore(NullnessStore s)
s
- a store to copypublic long getUid()
getUid
in interface org.plumelib.util.UniqueId
getUid
in class CFAbstractStore<NullnessValue,NullnessStore>
public NullnessStore leastUpperBound(NullnessStore other)
Store
Important: This method must fulfill the following contract:
this
.
other
.
this
, even if the signature is
more permissive.
leastUpperBound
in interface Store<NullnessStore>
leastUpperBound
in class InitializationStore<NullnessValue,NullnessStore>
protected boolean supersetOf(CFAbstractStore<NullnessValue,NullnessStore> o)
CFAbstractStore
CFAbstractStore
contains a superset of the map entries of the
argument CFAbstractStore
. Note that we test the entry keys and values by Java
equality, not by any subtype relationship. This method is used primarily to simplify the
equals predicate.supersetOf
in class InitializationStore<NullnessValue,NullnessStore>
protected String internalVisualize(CFGVisualizer<NullnessValue,NullnessStore,?> viz)
CFAbstractStore
viz
.internalVisualize
in class InitializationStore<NullnessValue,NullnessStore>
viz
- the visualizerStore
public boolean isPolyNullNonNull()
public void setPolyNullNonNull(boolean isPolyNullNonNull)
public boolean isPolyNullNull()