API docs for 1.3 release.
This commit is contained in:
@@ -0,0 +1,604 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
||||
<!--NewPage-->
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<!-- Generated by javadoc (build 1.6.0_24) on Wed Apr 06 17:00:09 PDT 2011 -->
|
||||
<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<TITLE>
|
||||
Card (vilya 1.3 API)
|
||||
</TITLE>
|
||||
|
||||
<META NAME="date" CONTENT="2011-04-06">
|
||||
|
||||
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
|
||||
|
||||
<SCRIPT type="text/javascript">
|
||||
function windowTitle()
|
||||
{
|
||||
if (location.href.indexOf('is-external=true') == -1) {
|
||||
parent.document.title="Card (vilya 1.3 API)";
|
||||
}
|
||||
}
|
||||
</SCRIPT>
|
||||
<NOSCRIPT>
|
||||
</NOSCRIPT>
|
||||
|
||||
</HEAD>
|
||||
|
||||
<BODY BGCOLOR="white" onload="windowTitle();">
|
||||
<HR>
|
||||
|
||||
|
||||
<!-- ========= START OF TOP NAVBAR ======= -->
|
||||
<A NAME="navbar_top"><!-- --></A>
|
||||
<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
|
||||
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
|
||||
<TR>
|
||||
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
|
||||
<A NAME="navbar_top_firstrow"><!-- --></A>
|
||||
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
|
||||
<TR ALIGN="center" VALIGN="top">
|
||||
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
|
||||
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
|
||||
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
|
||||
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/Card.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </TD>
|
||||
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
|
||||
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
|
||||
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
|
||||
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
|
||||
</EM>
|
||||
</TD>
|
||||
</TR>
|
||||
|
||||
<TR>
|
||||
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
||||
PREV CLASS
|
||||
<A HREF="../../../../../com/threerings/parlor/card/data/CardCodes.html" title="interface in com.threerings.parlor.card.data"><B>NEXT CLASS</B></A></FONT></TD>
|
||||
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
||||
<A HREF="../../../../../index.html?com/threerings/parlor/card/data/Card.html" target="_top"><B>FRAMES</B></A>
|
||||
<A HREF="Card.html" target="_top"><B>NO FRAMES</B></A>
|
||||
<SCRIPT type="text/javascript">
|
||||
<!--
|
||||
if(window==top) {
|
||||
document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
|
||||
}
|
||||
//-->
|
||||
</SCRIPT>
|
||||
<NOSCRIPT>
|
||||
<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
|
||||
</NOSCRIPT>
|
||||
|
||||
|
||||
</FONT></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
|
||||
SUMMARY: NESTED | FIELD | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD>
|
||||
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
|
||||
DETAIL: FIELD | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<A NAME="skip-navbar_top"></A>
|
||||
<!-- ========= END OF TOP NAVBAR ========= -->
|
||||
|
||||
<HR>
|
||||
<!-- ======== START OF CLASS DATA ======== -->
|
||||
<H2>
|
||||
<FONT SIZE="-1">
|
||||
com.threerings.parlor.card.data</FONT>
|
||||
<BR>
|
||||
Class Card</H2>
|
||||
<PRE>
|
||||
<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
|
||||
<IMG SRC="../../../../../resources/inherit.gif" ALT="extended by "><B>com.threerings.parlor.card.data.Card</B>
|
||||
</PRE>
|
||||
<DL>
|
||||
<DT><B>All Implemented Interfaces:</B> <DD>com.threerings.io.Streamable, <A HREF="../../../../../com/threerings/parlor/card/data/CardCodes.html" title="interface in com.threerings.parlor.card.data">CardCodes</A>, com.threerings.presents.data.InvocationCodes, com.threerings.presents.dobj.DSet.Entry, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A><<A HREF="../../../../../com/threerings/parlor/card/data/Card.html" title="class in com.threerings.parlor.card.data">Card</A>></DD>
|
||||
</DL>
|
||||
<HR>
|
||||
<DL>
|
||||
<DT><PRE>public class <B>Card</B><DT>extends <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A><DT>implements com.threerings.presents.dobj.DSet.Entry, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A><<A HREF="../../../../../com/threerings/parlor/card/data/Card.html" title="class in com.threerings.parlor.card.data">Card</A>>, <A HREF="../../../../../com/threerings/parlor/card/data/CardCodes.html" title="interface in com.threerings.parlor.card.data">CardCodes</A></DL>
|
||||
</PRE>
|
||||
|
||||
<P>
|
||||
Instances of this class represent individual playing cards.
|
||||
<P>
|
||||
|
||||
<P>
|
||||
<HR>
|
||||
|
||||
<P>
|
||||
<!-- ======== NESTED CLASS SUMMARY ======== -->
|
||||
|
||||
<A NAME="nested_class_summary"><!-- --></A>
|
||||
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
||||
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
||||
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
|
||||
<B>Nested Class Summary</B></FONT></TH>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<A NAME="nested_classes_inherited_from_class_com.threerings.io.Streamable"><!-- --></A>
|
||||
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
||||
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
|
||||
<TH ALIGN="left"><B>Nested classes/interfaces inherited from interface com.threerings.io.Streamable</B></TH>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD><CODE>com.threerings.io.Streamable.Closure</CODE></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
|
||||
<!-- =========== FIELD SUMMARY =========== -->
|
||||
|
||||
<A NAME="field_summary"><!-- --></A>
|
||||
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
||||
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
||||
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
|
||||
<B>Field Summary</B></FONT></TH>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<A NAME="fields_inherited_from_class_com.threerings.parlor.card.data.CardCodes"><!-- --></A>
|
||||
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
||||
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
|
||||
<TH ALIGN="left"><B>Fields inherited from interface com.threerings.parlor.card.data.<A HREF="../../../../../com/threerings/parlor/card/data/CardCodes.html" title="interface in com.threerings.parlor.card.data">CardCodes</A></B></TH>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD><CODE><A HREF="../../../../../com/threerings/parlor/card/data/CardCodes.html#ACE">ACE</A>, <A HREF="../../../../../com/threerings/parlor/card/data/CardCodes.html#BLACK_JOKER">BLACK_JOKER</A>, <A HREF="../../../../../com/threerings/parlor/card/data/CardCodes.html#CLUBS">CLUBS</A>, <A HREF="../../../../../com/threerings/parlor/card/data/CardCodes.html#DIAMONDS">DIAMONDS</A>, <A HREF="../../../../../com/threerings/parlor/card/data/CardCodes.html#HEARTS">HEARTS</A>, <A HREF="../../../../../com/threerings/parlor/card/data/CardCodes.html#JACK">JACK</A>, <A HREF="../../../../../com/threerings/parlor/card/data/CardCodes.html#KING">KING</A>, <A HREF="../../../../../com/threerings/parlor/card/data/CardCodes.html#QUEEN">QUEEN</A>, <A HREF="../../../../../com/threerings/parlor/card/data/CardCodes.html#RED_JOKER">RED_JOKER</A>, <A HREF="../../../../../com/threerings/parlor/card/data/CardCodes.html#SPADES">SPADES</A></CODE></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<A NAME="fields_inherited_from_class_com.threerings.presents.data.InvocationCodes"><!-- --></A>
|
||||
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
||||
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
|
||||
<TH ALIGN="left"><B>Fields inherited from interface com.threerings.presents.data.InvocationCodes</B></TH>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD><CODE>ACCESS_DENIED, E_ACCESS_DENIED, E_INTERNAL_ERROR, GLOBAL_GROUP, INTERNAL_ERROR</CODE></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
|
||||
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
|
||||
|
||||
<A NAME="constructor_summary"><!-- --></A>
|
||||
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
||||
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
||||
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
|
||||
<B>Constructor Summary</B></FONT></TH>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD><CODE><B><A HREF="../../../../../com/threerings/parlor/card/data/Card.html#Card()">Card</A></B>()</CODE>
|
||||
|
||||
<BR>
|
||||
No-arg constructor for deserialization.</TD>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD><CODE><B><A HREF="../../../../../com/threerings/parlor/card/data/Card.html#Card(int, int)">Card</A></B>(int number,
|
||||
int suit)</CODE>
|
||||
|
||||
<BR>
|
||||
Creates a new card.</TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
|
||||
<!-- ========== METHOD SUMMARY =========== -->
|
||||
|
||||
<A NAME="method_summary"><!-- --></A>
|
||||
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
||||
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
||||
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
|
||||
<B>Method Summary</B></FONT></TH>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
||||
<CODE> int</CODE></FONT></TD>
|
||||
<TD><CODE><B><A HREF="../../../../../com/threerings/parlor/card/data/Card.html#compareTo(com.threerings.parlor.card.data.Card)">compareTo</A></B>(<A HREF="../../../../../com/threerings/parlor/card/data/Card.html" title="class in com.threerings.parlor.card.data">Card</A> other)</CODE>
|
||||
|
||||
<BR>
|
||||
Compares this card to another.</TD>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
||||
<CODE> boolean</CODE></FONT></TD>
|
||||
<TD><CODE><B><A HREF="../../../../../com/threerings/parlor/card/data/Card.html#equals(java.lang.Object)">equals</A></B>(<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A> other)</CODE>
|
||||
|
||||
<BR>
|
||||
</TD>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
||||
<CODE> <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A><?></CODE></FONT></TD>
|
||||
<TD><CODE><B><A HREF="../../../../../com/threerings/parlor/card/data/Card.html#getKey()">getKey</A></B>()</CODE>
|
||||
|
||||
<BR>
|
||||
</TD>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
||||
<CODE> int</CODE></FONT></TD>
|
||||
<TD><CODE><B><A HREF="../../../../../com/threerings/parlor/card/data/Card.html#getNumber()">getNumber</A></B>()</CODE>
|
||||
|
||||
<BR>
|
||||
Returns the value of the card, either from 2 to 11 or KING, QUEEN, JACK, ACE, RED_JOKER, or
|
||||
BLACK_JOKER.</TD>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
||||
<CODE> int</CODE></FONT></TD>
|
||||
<TD><CODE><B><A HREF="../../../../../com/threerings/parlor/card/data/Card.html#getSuit()">getSuit</A></B>()</CODE>
|
||||
|
||||
<BR>
|
||||
Returns the suit of the card: SPADES, HEARTS, DIAMONDS, or CLUBS.</TD>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
||||
<CODE> int</CODE></FONT></TD>
|
||||
<TD><CODE><B><A HREF="../../../../../com/threerings/parlor/card/data/Card.html#hashCode()">hashCode</A></B>()</CODE>
|
||||
|
||||
<BR>
|
||||
</TD>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
||||
<CODE> boolean</CODE></FONT></TD>
|
||||
<TD><CODE><B><A HREF="../../../../../com/threerings/parlor/card/data/Card.html#isAce()">isAce</A></B>()</CODE>
|
||||
|
||||
<BR>
|
||||
Checks whether the card is an ace.</TD>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
||||
<CODE> boolean</CODE></FONT></TD>
|
||||
<TD><CODE><B><A HREF="../../../../../com/threerings/parlor/card/data/Card.html#isFace()">isFace</A></B>()</CODE>
|
||||
|
||||
<BR>
|
||||
Checks whether the card is a face card (KING, QUEEN, or JACK).</TD>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
||||
<CODE> boolean</CODE></FONT></TD>
|
||||
<TD><CODE><B><A HREF="../../../../../com/threerings/parlor/card/data/Card.html#isJoker()">isJoker</A></B>()</CODE>
|
||||
|
||||
<BR>
|
||||
Checks whether the card is a joker.</TD>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
||||
<CODE> boolean</CODE></FONT></TD>
|
||||
<TD><CODE><B><A HREF="../../../../../com/threerings/parlor/card/data/Card.html#isNumber()">isNumber</A></B>()</CODE>
|
||||
|
||||
<BR>
|
||||
Checks whether the card is a number card (2 to 10).</TD>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
||||
<CODE> boolean</CODE></FONT></TD>
|
||||
<TD><CODE><B><A HREF="../../../../../com/threerings/parlor/card/data/Card.html#isValid()">isValid</A></B>()</CODE>
|
||||
|
||||
<BR>
|
||||
Checks whether or not this card is valid.</TD>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
||||
<CODE> <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
|
||||
<TD><CODE><B><A HREF="../../../../../com/threerings/parlor/card/data/Card.html#toString()">toString</A></B>()</CODE>
|
||||
|
||||
<BR>
|
||||
</TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
|
||||
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
||||
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
|
||||
<TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
|
||||
</TR>
|
||||
<TR BGCOLOR="white" CLASS="TableRowColor">
|
||||
<TD><CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang">getClass</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang">notify</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang">notifyAll</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
|
||||
<P>
|
||||
|
||||
<!-- ========= CONSTRUCTOR DETAIL ======== -->
|
||||
|
||||
<A NAME="constructor_detail"><!-- --></A>
|
||||
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
||||
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
||||
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
|
||||
<B>Constructor Detail</B></FONT></TH>
|
||||
</TR>
|
||||
</TABLE>
|
||||
|
||||
<A NAME="Card()"><!-- --></A><H3>
|
||||
Card</H3>
|
||||
<PRE>
|
||||
public <B>Card</B>()</PRE>
|
||||
<DL>
|
||||
<DD>No-arg constructor for deserialization.
|
||||
<P>
|
||||
</DL>
|
||||
<HR>
|
||||
|
||||
<A NAME="Card(int, int)"><!-- --></A><H3>
|
||||
Card</H3>
|
||||
<PRE>
|
||||
public <B>Card</B>(int number,
|
||||
int suit)</PRE>
|
||||
<DL>
|
||||
<DD>Creates a new card.
|
||||
<P>
|
||||
<DL>
|
||||
<DT><B>Parameters:</B><DD><CODE>number</CODE> - the number of the card<DD><CODE>suit</CODE> - the suit of the card</DL>
|
||||
</DL>
|
||||
|
||||
<!-- ============ METHOD DETAIL ========== -->
|
||||
|
||||
<A NAME="method_detail"><!-- --></A>
|
||||
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
||||
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
||||
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
|
||||
<B>Method Detail</B></FONT></TH>
|
||||
</TR>
|
||||
</TABLE>
|
||||
|
||||
<A NAME="getNumber()"><!-- --></A><H3>
|
||||
getNumber</H3>
|
||||
<PRE>
|
||||
public int <B>getNumber</B>()</PRE>
|
||||
<DL>
|
||||
<DD>Returns the value of the card, either from 2 to 11 or KING, QUEEN, JACK, ACE, RED_JOKER, or
|
||||
BLACK_JOKER.
|
||||
<P>
|
||||
<DD><DL>
|
||||
</DL>
|
||||
</DD>
|
||||
<DD><DL>
|
||||
|
||||
<DT><B>Returns:</B><DD>the value of the card</DL>
|
||||
</DD>
|
||||
</DL>
|
||||
<HR>
|
||||
|
||||
<A NAME="getSuit()"><!-- --></A><H3>
|
||||
getSuit</H3>
|
||||
<PRE>
|
||||
public int <B>getSuit</B>()</PRE>
|
||||
<DL>
|
||||
<DD>Returns the suit of the card: SPADES, HEARTS, DIAMONDS, or CLUBS. If the card is the joker,
|
||||
the suit is undefined.
|
||||
<P>
|
||||
<DD><DL>
|
||||
</DL>
|
||||
</DD>
|
||||
<DD><DL>
|
||||
|
||||
<DT><B>Returns:</B><DD>the suit of the card</DL>
|
||||
</DD>
|
||||
</DL>
|
||||
<HR>
|
||||
|
||||
<A NAME="isNumber()"><!-- --></A><H3>
|
||||
isNumber</H3>
|
||||
<PRE>
|
||||
public boolean <B>isNumber</B>()</PRE>
|
||||
<DL>
|
||||
<DD>Checks whether the card is a number card (2 to 10).
|
||||
<P>
|
||||
<DD><DL>
|
||||
</DL>
|
||||
</DD>
|
||||
<DD><DL>
|
||||
|
||||
<DT><B>Returns:</B><DD>true if the card is a number card, false otherwise</DL>
|
||||
</DD>
|
||||
</DL>
|
||||
<HR>
|
||||
|
||||
<A NAME="isFace()"><!-- --></A><H3>
|
||||
isFace</H3>
|
||||
<PRE>
|
||||
public boolean <B>isFace</B>()</PRE>
|
||||
<DL>
|
||||
<DD>Checks whether the card is a face card (KING, QUEEN, or JACK).
|
||||
<P>
|
||||
<DD><DL>
|
||||
</DL>
|
||||
</DD>
|
||||
<DD><DL>
|
||||
|
||||
<DT><B>Returns:</B><DD>true if the card is a face card, false otherwise</DL>
|
||||
</DD>
|
||||
</DL>
|
||||
<HR>
|
||||
|
||||
<A NAME="isAce()"><!-- --></A><H3>
|
||||
isAce</H3>
|
||||
<PRE>
|
||||
public boolean <B>isAce</B>()</PRE>
|
||||
<DL>
|
||||
<DD>Checks whether the card is an ace.
|
||||
<P>
|
||||
<DD><DL>
|
||||
</DL>
|
||||
</DD>
|
||||
<DD><DL>
|
||||
|
||||
<DT><B>Returns:</B><DD>true if the card is an ace, false otherwise</DL>
|
||||
</DD>
|
||||
</DL>
|
||||
<HR>
|
||||
|
||||
<A NAME="isJoker()"><!-- --></A><H3>
|
||||
isJoker</H3>
|
||||
<PRE>
|
||||
public boolean <B>isJoker</B>()</PRE>
|
||||
<DL>
|
||||
<DD>Checks whether the card is a joker.
|
||||
<P>
|
||||
<DD><DL>
|
||||
</DL>
|
||||
</DD>
|
||||
<DD><DL>
|
||||
|
||||
<DT><B>Returns:</B><DD>true if the card is a joker, false otherwise</DL>
|
||||
</DD>
|
||||
</DL>
|
||||
<HR>
|
||||
|
||||
<A NAME="isValid()"><!-- --></A><H3>
|
||||
isValid</H3>
|
||||
<PRE>
|
||||
public boolean <B>isValid</B>()</PRE>
|
||||
<DL>
|
||||
<DD>Checks whether or not this card is valid. The no-arg public constructor for deserialization
|
||||
creates an invalid card.
|
||||
<P>
|
||||
<DD><DL>
|
||||
</DL>
|
||||
</DD>
|
||||
<DD><DL>
|
||||
|
||||
<DT><B>Returns:</B><DD>true if this card is valid, false if not</DL>
|
||||
</DD>
|
||||
</DL>
|
||||
<HR>
|
||||
|
||||
<A NAME="getKey()"><!-- --></A><H3>
|
||||
getKey</H3>
|
||||
<PRE>
|
||||
public <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A><?> <B>getKey</B>()</PRE>
|
||||
<DL>
|
||||
<DD><DL>
|
||||
<DT><B>Specified by:</B><DD><CODE>getKey</CODE> in interface <CODE>com.threerings.presents.dobj.DSet.Entry</CODE></DL>
|
||||
</DD>
|
||||
<DD><DL>
|
||||
</DL>
|
||||
</DD>
|
||||
</DL>
|
||||
<HR>
|
||||
|
||||
<A NAME="hashCode()"><!-- --></A><H3>
|
||||
hashCode</H3>
|
||||
<PRE>
|
||||
public int <B>hashCode</B>()</PRE>
|
||||
<DL>
|
||||
<DD><DL>
|
||||
<DT><B>Overrides:</B><DD><CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</A></CODE> in class <CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
|
||||
</DD>
|
||||
<DD><DL>
|
||||
</DL>
|
||||
</DD>
|
||||
</DL>
|
||||
<HR>
|
||||
|
||||
<A NAME="equals(java.lang.Object)"><!-- --></A><H3>
|
||||
equals</H3>
|
||||
<PRE>
|
||||
public boolean <B>equals</B>(<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A> other)</PRE>
|
||||
<DL>
|
||||
<DD><DL>
|
||||
<DT><B>Overrides:</B><DD><CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</A></CODE> in class <CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
|
||||
</DD>
|
||||
<DD><DL>
|
||||
</DL>
|
||||
</DD>
|
||||
</DL>
|
||||
<HR>
|
||||
|
||||
<A NAME="compareTo(com.threerings.parlor.card.data.Card)"><!-- --></A><H3>
|
||||
compareTo</H3>
|
||||
<PRE>
|
||||
public int <B>compareTo</B>(<A HREF="../../../../../com/threerings/parlor/card/data/Card.html" title="class in com.threerings.parlor.card.data">Card</A> other)</PRE>
|
||||
<DL>
|
||||
<DD>Compares this card to another. The card order is the same as the initial deck ordering: two
|
||||
through ten, jack, queen, king, ace for spades, hearts, clubs, and diamonds, then the red
|
||||
joker and the black joker.
|
||||
<P>
|
||||
<DD><DL>
|
||||
<DT><B>Specified by:</B><DD><CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Comparable.html?is-external=true#compareTo(T)" title="class or interface in java.lang">compareTo</A></CODE> in interface <CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A><<A HREF="../../../../../com/threerings/parlor/card/data/Card.html" title="class in com.threerings.parlor.card.data">Card</A>></CODE></DL>
|
||||
</DD>
|
||||
<DD><DL>
|
||||
<DT><B>Parameters:</B><DD><CODE>other</CODE> - the other card to compare this to
|
||||
<DT><B>Returns:</B><DD>-1, 0, or +1, depending on whether this card is less than, equal to, or greater
|
||||
than the other card</DL>
|
||||
</DD>
|
||||
</DL>
|
||||
<HR>
|
||||
|
||||
<A NAME="toString()"><!-- --></A><H3>
|
||||
toString</H3>
|
||||
<PRE>
|
||||
public <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>toString</B>()</PRE>
|
||||
<DL>
|
||||
<DD><DL>
|
||||
<DT><B>Overrides:</B><DD><CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</A></CODE> in class <CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
|
||||
</DD>
|
||||
<DD><DL>
|
||||
</DL>
|
||||
</DD>
|
||||
</DL>
|
||||
<!-- ========= END OF CLASS DATA ========= -->
|
||||
<HR>
|
||||
|
||||
|
||||
<!-- ======= START OF BOTTOM NAVBAR ====== -->
|
||||
<A NAME="navbar_bottom"><!-- --></A>
|
||||
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
|
||||
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
|
||||
<TR>
|
||||
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
|
||||
<A NAME="navbar_bottom_firstrow"><!-- --></A>
|
||||
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
|
||||
<TR ALIGN="center" VALIGN="top">
|
||||
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
|
||||
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
|
||||
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
|
||||
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/Card.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </TD>
|
||||
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
|
||||
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
|
||||
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
|
||||
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
|
||||
</EM>
|
||||
</TD>
|
||||
</TR>
|
||||
|
||||
<TR>
|
||||
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
||||
PREV CLASS
|
||||
<A HREF="../../../../../com/threerings/parlor/card/data/CardCodes.html" title="interface in com.threerings.parlor.card.data"><B>NEXT CLASS</B></A></FONT></TD>
|
||||
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
||||
<A HREF="../../../../../index.html?com/threerings/parlor/card/data/Card.html" target="_top"><B>FRAMES</B></A>
|
||||
<A HREF="Card.html" target="_top"><B>NO FRAMES</B></A>
|
||||
<SCRIPT type="text/javascript">
|
||||
<!--
|
||||
if(window==top) {
|
||||
document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
|
||||
}
|
||||
//-->
|
||||
</SCRIPT>
|
||||
<NOSCRIPT>
|
||||
<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
|
||||
</NOSCRIPT>
|
||||
|
||||
|
||||
</FONT></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
|
||||
SUMMARY: NESTED | FIELD | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD>
|
||||
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
|
||||
DETAIL: FIELD | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<A NAME="skip-navbar_bottom"></A>
|
||||
<!-- ======== END OF BOTTOM NAVBAR ======= -->
|
||||
|
||||
<HR>
|
||||
Copyright © 2011. All Rights Reserved.
|
||||
</BODY>
|
||||
</HTML>
|
||||
Reference in New Issue
Block a user