|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.hedgehog.HObject
com.hedgehog.game.Dice
public class Dice
Title: Dice - models a collecton of Die.
Description: Models a collection of Die.
Copyright: Copyright (c) Hedgehog Software 2007-2009.
Company: Hedgehog Software.
| Field Summary | |
|---|---|
protected Die[] |
mDice
Array of die. |
| Fields inherited from class com.hedgehog.HObject |
|---|
mID, mName |
| Constructor Summary | |
|---|---|
Dice()
Default constructor. |
|
Dice(Dice object)
Copy constructor. |
|
Dice(int numberDie)
Constructor. |
|
| Method Summary | |
|---|---|
Die |
die(int dieIndex)
Returns the die having the speified index. |
Die[] |
getDie()
Returns the array of die. |
int |
numberDie()
Returns the number of die. |
void |
setDie(Die[] die)
Sets the array of die. |
java.lang.String |
toString()
Returns a String representation of this Dice object. |
| Methods inherited from class com.hedgehog.HObject |
|---|
clone, compare, compareTo, copy, equals, getID, getName, hashCode, hasID, hasName, setID, setName |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected Die[] mDice
| Constructor Detail |
|---|
public Dice()
public Dice(int numberDie)
throws java.lang.IllegalArgumentException
numberDie - Number of die.
java.lang.IllegalArgumentException - Thrown if numberDie <= 0.public Dice(Dice object)
object - Object to copy.| Method Detail |
|---|
public Die[] getDie()
public void setDie(Die[] die)
die - New array of die.public int numberDie()
public Die die(int dieIndex)
throws java.lang.IllegalArgumentException
dieIndex - Die index.
java.lang.IllegalArgumentException - Thrown if the specified die index is invalid.public java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||