summaryrefslogtreecommitdiffstats
path: root/doc/jrummikub/model/StoneSet.html
diff options
context:
space:
mode:
authorIda Massow <massow@informatik.uni-luebeck.de>2011-07-06 16:36:06 +0200
committerIda Massow <massow@informatik.uni-luebeck.de>2011-07-06 16:36:06 +0200
commit51b7fbe822bd9a3804c061f0b844884769d7ddba (patch)
tree152d79321131936d1bc49e959d2a7a2628c592cb /doc/jrummikub/model/StoneSet.html
parent3193477354fc63477a3f42c94023fa84c129adf1 (diff)
downloadJRummikub-master.tar
JRummikub-master.zip
JavadocHEADmaster
git-svn-id: svn://sunsvr01.isp.uni-luebeck.de/swproj13/trunk@609 72836036-5685-4462-b002-a69064685172
Diffstat (limited to 'doc/jrummikub/model/StoneSet.html')
-rw-r--r--doc/jrummikub/model/StoneSet.html175
1 files changed, 147 insertions, 28 deletions
diff --git a/doc/jrummikub/model/StoneSet.html b/doc/jrummikub/model/StoneSet.html
index c476ebe..0cf4073 100644
--- a/doc/jrummikub/model/StoneSet.html
+++ b/doc/jrummikub/model/StoneSet.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_22) on Tue May 10 17:04:58 CEST 2011 -->
+<!-- Generated by javadoc (build 1.6.0_22) on Tue Jul 05 21:51:55 CEST 2011 -->
<TITLE>
StoneSet
</TITLE>
-<META NAME="date" CONTENT="2011-05-10">
+<META NAME="date" CONTENT="2011-07-05">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../stylesheet.css" TITLE="Style">
@@ -96,11 +96,11 @@ java.lang.Object
<IMG SRC="../../resources/inherit.gif" ALT="extended by "><B>jrummikub.model.StoneSet</B>
</PRE>
<DL>
-<DT><B>All Implemented Interfaces:</B> <DD>java.lang.Iterable&lt;<A HREF="../../jrummikub/model/Stone.html" title="class in jrummikub.model">Stone</A>&gt;, <A HREF="../../jrummikub/model/Sizeable.html" title="interface in jrummikub.model">Sizeable</A></DD>
+<DT><B>All Implemented Interfaces:</B> <DD>java.io.Serializable, java.lang.Iterable&lt;<A HREF="../../jrummikub/model/Stone.html" title="class in jrummikub.model">Stone</A>&gt;, <A HREF="../../jrummikub/model/Sizeable.html" title="interface in jrummikub.model">Sizeable</A></DD>
</DL>
<HR>
<DL>
-<DT><PRE>public class <B>StoneSet</B><DT>extends java.lang.Object<DT>implements java.lang.Iterable&lt;<A HREF="../../jrummikub/model/Stone.html" title="class in jrummikub.model">Stone</A>&gt;, <A HREF="../../jrummikub/model/Sizeable.html" title="interface in jrummikub.model">Sizeable</A></DL>
+<DT><PRE>public class <B>StoneSet</B><DT>extends java.lang.Object<DT>implements java.lang.Iterable&lt;<A HREF="../../jrummikub/model/Stone.html" title="class in jrummikub.model">Stone</A>&gt;, <A HREF="../../jrummikub/model/Sizeable.html" title="interface in jrummikub.model">Sizeable</A>, java.io.Serializable</DL>
</PRE>
<P>
@@ -108,6 +108,8 @@ Class managing <A HREF="../../jrummikub/model/Stone.html" title="class in jrummi
<P>
<P>
+<DL>
+<DT><B>See Also:</B><DD><A HREF="../../serialized-form.html#jrummikub.model.StoneSet">Serialized Form</A></DL>
<HR>
<P>
@@ -146,6 +148,22 @@ Class managing <A HREF="../../jrummikub/model/Stone.html" title="class in jrummi
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
+<CODE>private static&nbsp;long</CODE></FONT></TD>
+<TD><CODE><B><A HREF="../../jrummikub/model/StoneSet.html#serialVersionUID">serialVersionUID</A></B></CODE>
+
+<BR>
+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
+</TR>
+<TR BGCOLOR="white" CLASS="TableRowColor">
+<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
+<CODE>private &nbsp;java.util.ArrayList&lt;<A HREF="../../jrummikub/model/Stone.html" title="class in jrummikub.model">Stone</A>&gt;</CODE></FONT></TD>
+<TD><CODE><B><A HREF="../../jrummikub/model/StoneSet.html#stones">stones</A></B></CODE>
+
+<BR>
+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
+</TR>
+<TR BGCOLOR="white" CLASS="TableRowColor">
+<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>(package private) static&nbsp;float</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../jrummikub/model/StoneSet.html#VERTICAL_BORDER">VERTICAL_BORDER</A></B></CODE>
@@ -186,12 +204,21 @@ Class managing <A HREF="../../jrummikub/model/Stone.html" title="class in jrummi
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;<A HREF="../../jrummikub/model/StoneSet.Type.html" title="enum in jrummikub.model">StoneSet.Type</A></CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../jrummikub/model/StoneSet.html#classify()">classify</A></B>()</CODE>
+<CODE>&nbsp;<A HREF="../../jrummikub/util/Pair.html" title="class in jrummikub.util">Pair</A>&lt;<A HREF="../../jrummikub/model/StoneSet.Type.html" title="enum in jrummikub.model">StoneSet.Type</A>,java.lang.Integer&gt;</CODE></FONT></TD>
+<TD><CODE><B><A HREF="../../jrummikub/model/StoneSet.html#classify(jrummikub.model.GameSettings)">classify</A></B>(<A HREF="../../jrummikub/model/GameSettings.html" title="class in jrummikub.model">GameSettings</A>&nbsp;settings)</CODE>
<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Test for rule conflict within the StoneSet and determine whether the set
- is a group or a run</TD>
+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Test for rule conflict within the StoneSet and determine whether the set is
+ a group or a run</TD>
+</TR>
+<TR BGCOLOR="white" CLASS="TableRowColor">
+<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
+<CODE>private &nbsp;<A HREF="../../jrummikub/util/Pair.html" title="class in jrummikub.util">Pair</A>&lt;<A HREF="../../jrummikub/model/StoneSet.Type.html" title="enum in jrummikub.model">StoneSet.Type</A>,java.lang.Integer&gt;</CODE></FONT></TD>
+<TD><CODE><B><A HREF="../../jrummikub/model/StoneSet.html#classifyJokersOnly(jrummikub.model.GameSettings)">classifyJokersOnly</A></B>(<A HREF="../../jrummikub/model/GameSettings.html" title="class in jrummikub.model">GameSettings</A>&nbsp;settings)</CODE>
+
+<BR>
+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Test for rule conflict within a StoneSet with jokers only and determine
+ whether the set is a group or a run</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
@@ -211,6 +238,14 @@ Class managing <A HREF="../../jrummikub/model/Stone.html" title="class in jrummi
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
+<CODE>&nbsp;int</CODE></FONT></TD>
+<TD><CODE><B><A HREF="../../jrummikub/model/StoneSet.html#getSize()">getSize</A></B>()</CODE>
+
+<BR>
+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the number of stones in the set.</TD>
+</TR>
+<TR BGCOLOR="white" CLASS="TableRowColor">
+<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;float</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../jrummikub/model/StoneSet.html#getWidth()">getWidth</A></B>()</CODE>
@@ -220,13 +255,31 @@ Class managing <A HREF="../../jrummikub/model/Stone.html" title="class in jrummi
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;boolean</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../jrummikub/model/StoneSet.html#isValid()">isValid</A></B>()</CODE>
+<TD><CODE><B><A HREF="../../jrummikub/model/StoneSet.html#isValid(jrummikub.model.GameSettings)">isValid</A></B>(<A HREF="../../jrummikub/model/GameSettings.html" title="class in jrummikub.model">GameSettings</A>&nbsp;settings)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Test for rule conflict within the StoneSet</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
+<CODE>private &nbsp;int</CODE></FONT></TD>
+<TD><CODE><B><A HREF="../../jrummikub/model/StoneSet.html#isValidGroup(int, jrummikub.model.GameSettings)">isValidGroup</A></B>(int&nbsp;value,
+ <A HREF="../../jrummikub/model/GameSettings.html" title="class in jrummikub.model">GameSettings</A>&nbsp;settings)</CODE>
+
+<BR>
+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Test for rule conflict within the StoneSet, assuming we have a group</TD>
+</TR>
+<TR BGCOLOR="white" CLASS="TableRowColor">
+<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
+<CODE>private &nbsp;int</CODE></FONT></TD>
+<TD><CODE><B><A HREF="../../jrummikub/model/StoneSet.html#isValidRun(int, jrummikub.model.GameSettings)">isValidRun</A></B>(int&nbsp;referencePosition,
+ <A HREF="../../jrummikub/model/GameSettings.html" title="class in jrummikub.model">GameSettings</A>&nbsp;settings)</CODE>
+
+<BR>
+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Test for rule conflict within the StoneSet, assuming we have a run</TD>
+</TR>
+<TR BGCOLOR="white" CLASS="TableRowColor">
+<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;java.util.Iterator&lt;<A HREF="../../jrummikub/model/Stone.html" title="class in jrummikub.model">Stone</A>&gt;</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../jrummikub/model/StoneSet.html#iterator()">iterator</A></B>()</CODE>
@@ -243,14 +296,6 @@ Class managing <A HREF="../../jrummikub/model/Stone.html" title="class in jrummi
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;int</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../jrummikub/model/StoneSet.html#size()">size</A></B>()</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the number of stones in the set.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../jrummikub/util/Pair.html" title="class in jrummikub.util">Pair</A>&lt;<A HREF="../../jrummikub/model/StoneSet.html" title="class in jrummikub.model">StoneSet</A>,<A HREF="../../jrummikub/model/StoneSet.html" title="class in jrummikub.model">StoneSet</A>&gt;</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../jrummikub/model/StoneSet.html#splitAt(int)">splitAt</A></B>(int&nbsp;position)</CODE>
@@ -289,6 +334,16 @@ Class managing <A HREF="../../jrummikub/model/Stone.html" title="class in jrummi
</TR>
</TABLE>
+<A NAME="serialVersionUID"><!-- --></A><H3>
+serialVersionUID</H3>
+<PRE>
+private static final long <B>serialVersionUID</B></PRE>
+<DL>
+<DL>
+<DT><B>See Also:</B><DD><A HREF="../../constant-values.html#jrummikub.model.StoneSet.serialVersionUID">Constant Field Values</A></DL>
+</DL>
+<HR>
+
<A NAME="VERTICAL_BORDER"><!-- --></A><H3>
VERTICAL_BORDER</H3>
<PRE>
@@ -307,6 +362,16 @@ static final float <B>HORIZONTAL_BORDER</B></PRE>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../constant-values.html#jrummikub.model.StoneSet.HORIZONTAL_BORDER">Constant Field Values</A></DL>
</DL>
+<HR>
+
+<A NAME="stones"><!-- --></A><H3>
+stones</H3>
+<PRE>
+private java.util.ArrayList&lt;<A HREF="../../jrummikub/model/Stone.html" title="class in jrummikub.model">Stone</A>&gt; <B>stones</B></PRE>
+<DL>
+<DL>
+</DL>
+</DL>
<!-- ========= CONSTRUCTOR DETAIL ======== -->
@@ -351,10 +416,10 @@ public <B>StoneSet</B>(java.util.List&lt;<A HREF="../../jrummikub/model/Stone.ht
</TR>
</TABLE>
-<A NAME="isValid()"><!-- --></A><H3>
+<A NAME="isValid(jrummikub.model.GameSettings)"><!-- --></A><H3>
isValid</H3>
<PRE>
-public boolean <B>isValid</B>()</PRE>
+public boolean <B>isValid</B>(<A HREF="../../jrummikub/model/GameSettings.html" title="class in jrummikub.model">GameSettings</A>&nbsp;settings)</PRE>
<DL>
<DD>Test for rule conflict within the StoneSet
<P>
@@ -362,26 +427,80 @@ public boolean <B>isValid</B>()</PRE>
</DL>
</DD>
<DD><DL>
-
+<DT><B>Parameters:</B><DD><CODE>settings</CODE> - GameSettings
<DT><B>Returns:</B><DD>true when the set is valid according to the rules</DL>
</DD>
</DL>
<HR>
-<A NAME="classify()"><!-- --></A><H3>
+<A NAME="classify(jrummikub.model.GameSettings)"><!-- --></A><H3>
classify</H3>
<PRE>
-public <A HREF="../../jrummikub/model/StoneSet.Type.html" title="enum in jrummikub.model">StoneSet.Type</A> <B>classify</B>()</PRE>
+public <A HREF="../../jrummikub/util/Pair.html" title="class in jrummikub.util">Pair</A>&lt;<A HREF="../../jrummikub/model/StoneSet.Type.html" title="enum in jrummikub.model">StoneSet.Type</A>,java.lang.Integer&gt; <B>classify</B>(<A HREF="../../jrummikub/model/GameSettings.html" title="class in jrummikub.model">GameSettings</A>&nbsp;settings)</PRE>
+<DL>
+<DD>Test for rule conflict within the StoneSet and determine whether the set is
+ a group or a run
+<P>
+<DD><DL>
+</DL>
+</DD>
+<DD><DL>
+<DT><B>Parameters:</B><DD><CODE>settings</CODE> - GameSettings
+<DT><B>Returns:</B><DD>GROUP or RUN for valid sets, INVALID otherwise and the points</DL>
+</DD>
+</DL>
+<HR>
+
+<A NAME="classifyJokersOnly(jrummikub.model.GameSettings)"><!-- --></A><H3>
+classifyJokersOnly</H3>
+<PRE>
+private <A HREF="../../jrummikub/util/Pair.html" title="class in jrummikub.util">Pair</A>&lt;<A HREF="../../jrummikub/model/StoneSet.Type.html" title="enum in jrummikub.model">StoneSet.Type</A>,java.lang.Integer&gt; <B>classifyJokersOnly</B>(<A HREF="../../jrummikub/model/GameSettings.html" title="class in jrummikub.model">GameSettings</A>&nbsp;settings)</PRE>
+<DL>
+<DD>Test for rule conflict within a StoneSet with jokers only and determine
+ whether the set is a group or a run
+<P>
+<DD><DL>
+</DL>
+</DD>
+<DD><DL>
+<DT><B>Parameters:</B><DD><CODE>settings</CODE> - the game settings
+<DT><B>Returns:</B><DD>GROUP or RUN for valid sets, INVALID otherwise and the points</DL>
+</DD>
+</DL>
+<HR>
+
+<A NAME="isValidRun(int, jrummikub.model.GameSettings)"><!-- --></A><H3>
+isValidRun</H3>
+<PRE>
+private int <B>isValidRun</B>(int&nbsp;referencePosition,
+ <A HREF="../../jrummikub/model/GameSettings.html" title="class in jrummikub.model">GameSettings</A>&nbsp;settings)</PRE>
<DL>
-<DD>Test for rule conflict within the StoneSet and determine whether the set
- is a group or a run
+<DD>Test for rule conflict within the StoneSet, assuming we have a run
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
+<DT><B>Parameters:</B><DD><CODE>referencePosition</CODE> - position of stone used as reference (any non-joker stone)<DD><CODE>settings</CODE> - the game settings
+<DT><B>Returns:</B><DD>the set's points</DL>
+</DD>
+</DL>
+<HR>
-<DT><B>Returns:</B><DD>GROUP or RUN for valid sets, INVALID otherwise</DL>
+<A NAME="isValidGroup(int, jrummikub.model.GameSettings)"><!-- --></A><H3>
+isValidGroup</H3>
+<PRE>
+private int <B>isValidGroup</B>(int&nbsp;value,
+ <A HREF="../../jrummikub/model/GameSettings.html" title="class in jrummikub.model">GameSettings</A>&nbsp;settings)</PRE>
+<DL>
+<DD>Test for rule conflict within the StoneSet, assuming we have a group
+<P>
+<DD><DL>
+</DL>
+</DD>
+<DD><DL>
+<DT><B>Parameters:</B><DD><CODE>value</CODE> - the value of the stones (all have the same in a group)<DD><CODE>settings</CODE> - the game settings
+<DT><B>Returns:</B><DD>the set's points</DL>
</DD>
</DL>
<HR>
@@ -421,10 +540,10 @@ public <A HREF="../../jrummikub/model/StoneSet.html" title="class in jrummikub.m
</DL>
<HR>
-<A NAME="size()"><!-- --></A><H3>
-size</H3>
+<A NAME="getSize()"><!-- --></A><H3>
+getSize</H3>
<PRE>
-public int <B>size</B>()</PRE>
+public int <B>getSize</B>()</PRE>
<DL>
<DD>Returns the number of stones in the set.
<P>