net.thestump.ghronos.timing.ot
Class Scrabble

java.lang.Object
  extended bynet.thestump.ghronos.timing.TimingStyle
      extended bynet.thestump.ghronos.timing.ot.OvertimeStyle
          extended bynet.thestump.ghronos.timing.ot.Scrabble
All Implemented Interfaces:
superwaba.ext.xplat.io.Storable

public class Scrabble
extends OvertimeStyle

Provides a Scrabble timing style.

Author:
Christopher C. Stump

Field Summary
static byte ID
          Timing style/Storable ID
static java.lang.String NAME
          Name of this timing style
 
Fields inherited from class net.thestump.ghronos.timing.ot.OvertimeStyle
bottomClockInOt, clockIsInOvertime, isAppliedTo, overtime, topClockInOt, topClockIsTicking
 
Fields inherited from class net.thestump.ghronos.timing.TimingStyle
appliedToBottomClock, appliedToTopClock, toStart, toStop
 
Constructor Summary
Scrabble()
           
 
Method Summary
 void execute(Clock tickingClock)
          Runs an overtime check on tickingClock when it runs out of time to see if it should go into overtime or not
 void execute(Clock topClock, Clock bottomClock)
          Applies the timing style to the appropriate clocks on a clock switch
 java.lang.String getDescription()
          Gets a description of this timing style which is used to display information about the timing style in a help dialog
 byte getID()
           
 superwaba.ext.xplat.io.Storable getInstance()
           
 void onRegister(Clock topClock, Clock bottomClock)
          Called when this TimingStyle is registered with the Mediator.
 void onUnRegister(Clock topClock, Clock bottomClock)
          Called when this TimingStyle is unregistered with the Mediator (when another TimingStyle is registered).
 void reset()
          Perform any resetting the timing style may need in between usages.
 void saveState(superwaba.ext.xplat.io.DataStream ds)
           
 java.lang.String toString()
           
 
Methods inherited from class net.thestump.ghronos.timing.ot.OvertimeStyle
evaluate, getOvertime, isInOvertime, loadState, setOvertime, setOvertime
 
Methods inherited from class net.thestump.ghronos.timing.TimingStyle
applyTo, isAppliedTo
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

ID

public static final byte ID
Timing style/Storable ID

See Also:
Constant Field Values

NAME

public static final java.lang.String NAME
Name of this timing style

See Also:
Constant Field Values
Constructor Detail

Scrabble

public Scrabble()
Method Detail

onUnRegister

public void onUnRegister(Clock topClock,
                         Clock bottomClock)
Description copied from class: TimingStyle
Called when this TimingStyle is unregistered with the Mediator (when another TimingStyle is registered). Is a place holder to do work before just before the timing style is trashed. Does nothing by default.

Overrides:
onUnRegister in class TimingStyle
Parameters:
topClock -
bottomClock -

onRegister

public void onRegister(Clock topClock,
                       Clock bottomClock)
Description copied from class: TimingStyle
Called when this TimingStyle is registered with the Mediator. Is a place holder to do work before just before the timing style is actually used. Does nothing by default. Note that this method IS NOT called when a timing style is recalled from the database

Overrides:
onRegister in class TimingStyle
Parameters:
topClock -
bottomClock -

execute

public void execute(Clock topClock,
                    Clock bottomClock)
Description copied from class: TimingStyle
Applies the timing style to the appropriate clocks on a clock switch

Specified by:
execute in class OvertimeStyle

reset

public void reset()
Description copied from class: OvertimeStyle
Perform any resetting the timing style may need in between usages.

Overrides:
reset in class OvertimeStyle

execute

public void execute(Clock tickingClock)
Description copied from class: OvertimeStyle
Runs an overtime check on tickingClock when it runs out of time to see if it should go into overtime or not

Specified by:
execute in class OvertimeStyle
Parameters:
tickingClock - The currently ticking clock which should be checked for overtime

toString

public java.lang.String toString()

getID

public byte getID()
Specified by:
getID in interface superwaba.ext.xplat.io.Storable
Specified by:
getID in class OvertimeStyle

getInstance

public superwaba.ext.xplat.io.Storable getInstance()
Specified by:
getInstance in interface superwaba.ext.xplat.io.Storable
Specified by:
getInstance in class OvertimeStyle

saveState

public void saveState(superwaba.ext.xplat.io.DataStream ds)
Specified by:
saveState in interface superwaba.ext.xplat.io.Storable
Overrides:
saveState in class OvertimeStyle

getDescription

public java.lang.String getDescription()
Description copied from class: TimingStyle
Gets a description of this timing style which is used to display information about the timing style in a help dialog

Specified by:
getDescription in class TimingStyle
Returns:
A brief description of how the timing style operates.


Copyright © 2004 Christopher C. Stump. All Rights Reserved.