Skip to content
Snippets Groups Projects
Commit baa781f0 authored by William Schultz's avatar William Schultz Committed by Markus Alexander Kuppe
Browse files

Remove unused diff method

parent 3cd7a366
No related branches found
No related tags found
No related merge requests found
......@@ -76,26 +76,6 @@ public abstract class TLCState implements Cloneable, Serializable {
return valMap;
}
/**
* Returns a map of all variables that are different between this state and 'otherState' along
* with their values in 'otherState'.
*/
public HashMap<UniqueString, Value> diff(TLCState otherState){
HashMap<UniqueString, Value> stateVals = this.getVals();
HashMap<UniqueString, Value> succStateVals = otherState.getVals();
HashMap<UniqueString, Value> diffMap = new HashMap<>();
for(UniqueString key : stateVals.keySet()) {
Value valSucc = succStateVals.get(key);
// Check if the value in the new state is different from the old state.
if(!stateVals.get(key).equals(valSucc)) {
diffMap.put(key, valSucc);
}
}
return diffMap;
}
/* Returns a string representation of this state. */
public abstract String toString();
public abstract String toString(TLCState lastState);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment