From a155f6ba02e08a75ce6e474a86900b8363f506e8 Mon Sep 17 00:00:00 2001 From: Kristóf Marussy Date: Wed, 29 Sep 2021 02:45:57 +0200 Subject: build: migration to Gradle 7 --- .../viatra/solver/data/map/internal/OldValueBox.java | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 store/src/main/java/org/eclipse/viatra/solver/data/map/internal/OldValueBox.java (limited to 'store/src/main/java/org/eclipse/viatra/solver/data/map/internal/OldValueBox.java') diff --git a/store/src/main/java/org/eclipse/viatra/solver/data/map/internal/OldValueBox.java b/store/src/main/java/org/eclipse/viatra/solver/data/map/internal/OldValueBox.java new file mode 100644 index 00000000..23502857 --- /dev/null +++ b/store/src/main/java/org/eclipse/viatra/solver/data/map/internal/OldValueBox.java @@ -0,0 +1,19 @@ +package org.eclipse.viatra.solver.data.map.internal; + +public class OldValueBox{ + V oldValue; + boolean isSet = false; + + public V getOldValue() { + if(!isSet) throw new IllegalStateException(); + isSet = false; + return oldValue; + } + + public void setOldValue(V ouldValue) { + if(isSet) throw new IllegalStateException(); + this.oldValue = ouldValue; + isSet = true; + } + +} -- cgit v1.2.3-54-g00ecf