Class sTools.SApplet
java.lang.Object
|
+----java.awt.Component
|
+----java.awt.Container
|
+----java.awt.Panel
|
+----java.applet.Applet
|
+----sTools.SApplet
- public class SApplet
- extends Applet
clock
-
dataConnections
-
dataListeners
-
dataSources
-
SApplet()
-
addDataListener(Object)
-
addDataSource(Object)
- Add a data source to the list.
cleanupDataConnections()
- Remove dataConnections if either the source or the listener no longer exist.
clearAllData()
- Delete all the data that has been sent to the DataConnections.
clearData(int)
- Delete all the data that has been sent to the DataConnections.
cyclingClock()
- Override this method if special action needs to be taken when the clock is cycled by the
SApplet.
deleteDataConnection(int)
- Break the data connection identified by the id.
deleteDataConnections()
- Break all data connections for this applet's instance.
destroy()
-
getClockID()
- Get the ID for use as a data source.
getDataConnectionFromDL(SDataListener)
- Find the first data connection in the list that has a specific data listener.
getDataConnectionFromDS(SDataSource)
- Find the first data connection in the list that has a specific data source.
getDataListener(int)
-
getDataListener(String)
-
getDataSource(int)
- Find the data source with the given id.
getDataSource(String)
- Find the data source with the given id.
getID()
-
getRunningID()
-
makeDataConnection(int,
int, int, String, String)
- Set the DataConnection for the applet.
removeDataListener(int)
-
removeDataSource(int)
- Remove the data source with the given id.
setClockContinous()
- Set the clock to run continously.
setClockCycle(double, double)
- Set the clock to cycle between the minTime and maxTime.
setClockOneShot(double, double)
- Set the clock to run from minTime to maxTime and stop.
setClockTime(double)
- Set the clock time.
setConnectionSmoothing(int, int)
- Have the data connection smooth the data before it is sent to the data listener.
setConnectionStride(int, int)
- Have the data connection smooth the data before it is sent to the data listener.
setRunningID()
-
setRunningID(Object)
-
startClock()
- Stop the clock
stopClock()
- Stop the clock
stoppingClock()
- Override this method if special action needs to be taken when the clock is stopped by
the SApplet.
updateDataConnection(int)
- Have a single data source update its data connections.
updateDataConnections()
- Have all data sources update their data to their connections.
useMasterClock()
- Sets applet to use the master clock shared by all applets.

dataSources
public static Hashtable dataSources

dataListeners
public static Hashtable dataListeners

clock
public SClock clock

dataConnections
public Vector dataConnections

SApplet
public SApplet()

destroy
public synchronized void destroy()
- Overrides:
- destroy in class Applet

makeDataConnection
public int makeDataConnection(int sourceID,
int listenerID,
int seriesID,
String xStr,
String yStr)
- Set the DataConnection for the applet.
- Parameters:
- sourceID - The id of the data source.
- listenerID - The id of the data listener. This is usually an applet.
- seriesID - The id of the series in the data listener.
- xStr - The function of the data source variables to be plotted on the horizontal axis.
- xStr - The function of the data source variables to be plotted on the vertical axis.

clearAllData
public void clearAllData()
- Delete all the data that has been sent to the DataConnections.

clearData
public void clearData(int id)
- Delete all the data that has been sent to the DataConnections.

updateDataConnection
public void updateDataConnection(int id)
- Have a single data source update its data connections.
- Parameters:
- id - The integer id of the data source.

updateDataConnections
public void updateDataConnections()
- Have all data sources update their data to their connections.

deleteDataConnections
public void deleteDataConnections()
- Break all data connections for this applet's instance.

deleteDataConnection
public void deleteDataConnection(int id)
- Break the data connection identified by the id.
- Parameters:
- id - The data connection id.

getDataConnectionFromDS
public SDataConnection getDataConnectionFromDS(SDataSource ds)
- Find the first data connection in the list that has a specific data source.
- Returns:
- s SDataConnection

getDataConnectionFromDL
public SDataConnection getDataConnectionFromDL(SDataListener dl)
- Find the first data connection in the list that has a specific data listener.
- Returns:
- s SDataConnection

cleanupDataConnections
public final void cleanupDataConnections()
- Remove dataConnections if either the source or the listener no longer exist.

getRunningID
public final Object getRunningID()

setRunningID
public final void setRunningID(Object id)

setRunningID
public final void setRunningID()

getID
public final int getID()

setConnectionSmoothing
public final boolean setConnectionSmoothing(int id,
int num)
- Have the data connection smooth the data before it is sent to the data listener.

setConnectionStride
public final boolean setConnectionStride(int id,
int num)
- Have the data connection smooth the data before it is sent to the data listener.

getClockID
public final int getClockID()
- Get the ID for use as a data source.

useMasterClock
public void useMasterClock()
- Sets applet to use the master clock shared by all applets. This process cannot be
reversed!

setClockTime
public void setClockTime(double t)
- Set the clock time.
- Parameters:
- t - The clock time.

setClockOneShot
public void setClockOneShot(double minTime,
double maxTime)
- Set the clock to run from minTime to maxTime and stop.
- Parameters:
- minTime - The maximum time.
- maxTime - The maximum time.

setClockContinous
public void setClockContinous()
- Set the clock to run continously.
- See Also:
- setClockOneShot, setClockCycle

setClockCycle
public void setClockCycle(double minTime,
double maxTime)
- Set the clock to cycle between the minTime and maxTime.
- Parameters:
- minTime - The maximum time.
- maxTime - The maximum time.

startClock
public void startClock()
- Stop the clock

stoppingClock
protected void stoppingClock()
- Override this method if special action needs to be taken when the clock is stopped by
the SApplet.

cyclingClock
protected void cyclingClock()
- Override this method if special action needs to be taken when the clock is cycled by the
SApplet.

stopClock
public void stopClock()
- Stop the clock

addDataSource
public static final void addDataSource(Object ds)
- Add a data source to the list.
- Parameters:
- ds - The data source object.

removeDataSource
public final void removeDataSource(int id)
- Remove the data source with the given id. Look for and remove data connections to this
data source.
- Parameters:
- id - The integer id that identifies the data source.

getDataSource
public static final SDataSource getDataSource(String key)
- Find the data source with the given id.
- Parameters:
- key - The string id that identifies the data source.

getDataSource
public static final SDataSource getDataSource(int id)
- Find the data source with the given id.
- Parameters:
- id - The integer id that identifies the data source.

removeDataListener
public final void removeDataListener(int key)

addDataListener
public static final void addDataListener(Object dl)

getDataListener
public static final SDataListener getDataListener(String key)

getDataListener
public static final SDataListener getDataListener(int key)