summaryrefslogtreecommitdiffstats
path: root/mock
diff options
context:
space:
mode:
Diffstat (limited to 'mock')
-rw-r--r--mock/jrummikub/model/MockHand.java11
-rw-r--r--mock/jrummikub/model/MockTable.java11
-rw-r--r--mock/jrummikub/view/MockView.java7
3 files changed, 29 insertions, 0 deletions
diff --git a/mock/jrummikub/model/MockHand.java b/mock/jrummikub/model/MockHand.java
index 13f6450..d282234 100644
--- a/mock/jrummikub/model/MockHand.java
+++ b/mock/jrummikub/model/MockHand.java
@@ -92,4 +92,15 @@ public class MockHand implements IHand {
public int getIdenticalStoneCount() {
return 0;
}
+
+ @Override
+ public boolean contains(Stone object) {
+ for (Pair<Stone, Position> stone : stones) {
+ if (stone.getFirst() == object) {
+ return true;
+ }
+ }
+
+ return false;
+ }
}
diff --git a/mock/jrummikub/model/MockTable.java b/mock/jrummikub/model/MockTable.java
index 295321c..77652a6 100644
--- a/mock/jrummikub/model/MockTable.java
+++ b/mock/jrummikub/model/MockTable.java
@@ -69,4 +69,15 @@ public class MockTable implements ITable {
return sets.size();
}
+ @Override
+ public boolean contains(StoneSet object) {
+ for (Pair<StoneSet, Position> set : sets) {
+ if (set.getFirst() == object) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
}
diff --git a/mock/jrummikub/view/MockView.java b/mock/jrummikub/view/MockView.java
index 7329907..167bc0b 100644
--- a/mock/jrummikub/view/MockView.java
+++ b/mock/jrummikub/view/MockView.java
@@ -5,6 +5,7 @@ import java.io.File;
import java.util.Collection;
import jrummikub.model.Stone;
+import jrummikub.model.StoneSet;
import jrummikub.util.IEvent;
import jrummikub.util.IEvent1;
import jrummikub.util.MockEvent;
@@ -237,4 +238,10 @@ public class MockView implements IView {
}
+ @Override
+ public void setInvalidStoneSets(Collection<StoneSet> sets) {
+ // TODO Auto-generated method stub
+
+ }
+
}