diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/jrummikub/model/StoneSet.java | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/src/jrummikub/model/StoneSet.java b/src/jrummikub/model/StoneSet.java index 706ed3b..d949187 100644 --- a/src/jrummikub/model/StoneSet.java +++ b/src/jrummikub/model/StoneSet.java @@ -1,13 +1,24 @@ package jrummikub.model; +import java.util.List; + import jrummikub.util.Pair; /** Class managing {@link Stone}s joined together to form sets */ public class StoneSet { private List<Stone> stones; + public StoneSet(Stone stone) { + + } + + public StoneSet(List<Stone> stones) { + + } + /** Test for rule conflict within the StoneSet */ public boolean isValid() { + return false; } @@ -19,6 +30,14 @@ public class StoneSet { * Splitting {@link Position} */ public Pair<StoneSet, StoneSet> splitAt(int position) { + //Exception falls falscher index + if (position==0||position==stones.size()){ + + } + else { + + } + return null; } @@ -29,7 +48,16 @@ public class StoneSet { * StoneSet to be joined to active StoneSet */ public StoneSet join(StoneSet other) { + return null; + + } + + public int size() { + return stones.size(); + } + public Stone get(int i) { + return stones.get(i); } } |