universe
Class Universe<Msg extends java.io.Serializable>

java.lang.Object
  extended by universe.Universe<Msg>
Direct Known Subclasses:
ChatServer, ShowServer

public abstract class Universe<Msg extends java.io.Serializable>
extends java.lang.Object

A Class representing a Universe (a collection of Worlds) of some type, and related methods and Function Objects for handling messages and events


Field Summary
static double DEFAULT_TICK_RATE
          Default Tick rate for the world
 
Constructor Summary
Universe()
          Empty Default Constructor
 
Method Summary
 Bundle<Msg> onDisconnect(IWorld w)
           
abstract  Scene onDraw()
           
 Bundle<Msg> onMsg(IWorld w, Msg msg)
           
 Bundle<Msg> onNew(IWorld w)
           
 Bundle<Msg> onTick()
           
 double tickRate()
          Return the tick rate for this World.
 Universe<Msg> universe()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_TICK_RATE

public static double DEFAULT_TICK_RATE
Default Tick rate for the world

Constructor Detail

Universe

public Universe()
Empty Default Constructor

Method Detail

onDraw

public abstract Scene onDraw()

onTick

public Bundle<Msg> onTick()

tickRate

public double tickRate()
Return the tick rate for this World. This is only accessed at the initial Universe creation.


onNew

public Bundle<Msg> onNew(IWorld w)

onDisconnect

public Bundle<Msg> onDisconnect(IWorld w)

onMsg

public Bundle<Msg> onMsg(IWorld w,
                         Msg msg)

universe

public Universe<Msg> universe()