Interface DieInterface


public interface DieInterface

Defines the methods that all "Die" objects must have.


Method Summary
 void roll()
          Rolls the Die object.
 int sides()
          Returns the number of sides of this die object.
 int top()
          Returns the current value on the top of this Die object.
 

Method Detail

sides

public int sides()
Returns the number of sides of this die object.


roll

public void roll()
Rolls the Die object. (Changes the value of top.)


top

public int top()
Returns the current value on the top of this Die object.