quicktime.app.spaces
Interface Space

All Superinterfaces:
Collection, DynamicCollection, Listener, Ticklish
All Known Subinterfaces:
QTDisplaySpace
All Known Implementing Classes:
SimpleSpace

public interface Space
extends Listener, DynamicCollection, Ticklish

A Space is a dynamic collection of members. A Space also has a Timer and a collection of Controllers. The Timer provides the parent TimeBase for all members and controllers within the Space that are themselves Spaces or objects that have a TimeBase. The getSource method returns the source object which the Space has been addedTo (ie. the Space is also a Listener).

The tickleList is the list of TicklishControllers that have been added to ths Space and will be tickled by the Space when the Space itself is tickled by its Timer.

A default implementation of the Space interface is provided in the SimpleSpace class - refer to the documentation for details of that implementation.

See Also:
SimpleSpace

Fields inherited from interface quicktime.app.time.Ticklish
kScale
 
Method Summary
 void addController(Controller c)
          This method is used by the application to add a Controller to the Space.
 java.util.Enumeration controllers()
          Returns an Enumeration of all Controllers that are currently attached to the Space.
 java.lang.Object getSource()
          This object is the source for all of the members and controllers of the Space that implement the Listener interface.
 Timer getTimer()
          Returns the Timer of the Space.
 void removeController(Controller c)
          Removes a controller that was previously added to the Space.
 java.util.Enumeration tickleList()
          Returns an Enumeration of all of the Controllers that implement the Ticklish interface (TicklishControllers) that have been added to the Space.
 
Methods inherited from interface quicktime.app.spaces.Listener
addedTo, removedFrom
 
Methods inherited from interface quicktime.app.spaces.DynamicCollection
getProtocol
 
Methods inherited from interface quicktime.app.spaces.Collection
addMember, hasMember, isAppropriate, isEmpty, members, removeMember, size
 
Methods inherited from interface quicktime.app.time.Ticklish
tickle, timeChanged
 

Method Detail

addController

public void addController(Controller c)
                   throws QTException
This method is used by the application to add a Controller to the Space. A Controller will control members of a Space.
Parameters:
c - the Controller to add to the Space.

removeController

public void removeController(Controller c)
                      throws QTException
Removes a controller that was previously added to the Space.
Parameters:
c - the Controller to remove from the Space.

controllers

public java.util.Enumeration controllers()
Returns an Enumeration of all Controllers that are currently attached to the Space.
Returns:
an Enumeration

tickleList

public java.util.Enumeration tickleList()
Returns an Enumeration of all of the Controllers that implement the Ticklish interface (TicklishControllers) that have been added to the Space. These controllers are tickled each time the Space itself is tickled by its Timer.
Returns:
an Enumeration of Ticklish objects

getTimer

public Timer getTimer()
Returns the Timer of the Space. This Timer provids a TimeBase for the Space and if active will tickle and send timeChanged calls to the TicklishControllers that are attached to the Space.
Returns:
a Timer

getSource

public java.lang.Object getSource()
This object is the source for all of the members and controllers of the Space that implement the Listener interface. All such members and controllers will have the same source as the parent space when it is addedTo a Listener source. If the parent Space has not been added to a Listener source this returns null.
Returns:
the Listener source object