|
*停權中*
|
定義了Suit, Rank這些variable type,後面method裡也是得回傳object裡的這些variable type.
改完試試看不知有沒好?
/*------------------------------------------
public Card(Suit suit, Rank rank, int value)
{
this.suit = suit;
this.rank = rank;
this.value = value;
}
/**
* Get the suit of the card
* @return String
*/
public Suit getSuit()
{
return this.suit;
}
/**
* Get the rank of the card
* @return String
*/
public Rank getRank()
{
return this.rank;
}
/**
* Get the actual value of the card
* @return int
*/
public int getValue()
{
return this.value;
}
}
-----------------------------*/
|