sopra
Class Timer

java.lang.Object
  |
  +--java.util.Observable
        |
        +--sopra.Timer
All Implemented Interfaces:
java.lang.Runnable

public class Timer
extends java.util.Observable
implements java.lang.Runnable


Nested Class Summary
 class Timer.MyThread
           
 
Field Summary
private static Timer exemplar
          Exemplar des Timers (es darf nur eines geben)
private  int sleepTime
          Zeitdauer in ms, welche der Timer schlafen soll
private  java.lang.Thread thread
          Thread, der aktiv ist
 
Fields inherited from class java.util.Observable
 
Constructor Summary
private Timer(int aSleepTime)
           
 
Method Summary
 void notifyObservers()
           
 void run()
           
private  int sleepTime()
           
private  void sleepTime(int anInteger)
           
static Timer start(int aSleepTime)
           
 
Methods inherited from class java.util.Observable
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, setChanged
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

exemplar

private static Timer exemplar
Exemplar des Timers (es darf nur eines geben)


sleepTime

private int sleepTime
Zeitdauer in ms, welche der Timer schlafen soll


thread

private java.lang.Thread thread
Thread, der aktiv ist

Constructor Detail

Timer

private Timer(int aSleepTime)
Method Detail

start

public static Timer start(int aSleepTime)

sleepTime

private void sleepTime(int anInteger)

sleepTime

private int sleepTime()

notifyObservers

public void notifyObservers()
Overrides:
notifyObservers in class java.util.Observable

run

public void run()
Specified by:
run in interface java.lang.Runnable