|
Chemistry AppletsDavid N. Blauch |
||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||
java.lang.Object
|
+--java.awt.Component
|
+--java.awt.Container
|
+--java.awt.Panel
|
+--java.applet.Applet
|
+--edu.davidson.tools.SApplet
|
+--data.Data
Data is an applet that serves two roles:
It acts as a relay between an SDataSource and JavaScript in a Web Page
It store data, which can be retrieved via other Applets or JavaScript
APPLET PARAMETERS
ShowLabel : if true the label is used
LabelWidth : width of the label in pixels
LabelHeight : height of the label in pixels
LabelID : ID of the data set whose x or y value is displayed in the label
ShowY : if true the y value is displayed in the label, if false the x value is displayed
| Fields inherited from class edu.davidson.tools.SApplet |
autoRefresh,
clock,
dataConnections,
dataListeners,
dataSources,
lock,
oneShotMsg |
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT,
CENTER_ALIGNMENT,
LEFT_ALIGNMENT,
RIGHT_ALIGNMENT,
TOP_ALIGNMENT |
| Constructor Summary | |
Data()
|
|
| Method Summary | |
void |
addData(edu.davidson.tools.SDataSource ds,
int id,
double[] x,
double[] y)
SDataListener Method: Use to submit an array of data points |
int |
addDataSet(java.lang.String func,
int id)
Adds a new Data Set with identification id. |
void |
addDatum(edu.davidson.tools.SDataSource ds,
int id,
double x,
double y)
SDataListener Method: Use to submit a single data point |
void |
callJavaScript(boolean val)
Determines whether JavaScript addData and addDatum functions are automatically called. |
void |
clearSeries(int id)
SDataListener Method: Clears the specified data set. |
void |
deleteSeries(int id)
SDataListener Method: Deletes the specified data set. |
void |
destroy()
|
java.lang.String |
getAppletInfo()
|
int |
getNumberPoints(int id)
Gets number of points in a set |
edu.davidson.tools.SApplet |
getOwner()
SDataListener Method: Returns the owner of this SDataListener |
java.lang.String |
getParameter(java.lang.String key,
java.lang.String def)
|
java.lang.String[][] |
getParameterInfo()
|
void |
init()
|
void |
setBackgroundColor(java.lang.String rgb)
Sets the background color of the applet |
void |
setLabelFont(java.awt.Font fnt)
Sets the font for the label. |
void |
setLabelFormat(int nbrLength,
int nbrDecimal)
Sets the format for the values displayed in the label |
void |
setLabelSize(int wid,
int ht)
Sets the size of the label. |
void |
setLabelText(java.lang.String val)
Sets the text in the label. |
void |
setOwner(edu.davidson.tools.SApplet owner)
SDataListener Method: Sets the owner of this SDataListener |
void |
start()
|
void |
stop()
|
| Methods inherited from class edu.davidson.tools.SApplet |
addDataListener,
addDataSource,
cleanupDataConnections,
clearAllData,
clearData,
cyclingClock,
deleteDataConnection,
deleteDataConnections,
forward,
getClockID,
getClockTime,
getDataConnectionFromDL,
getDataConnectionFromDS,
getDataFromDS,
getDataListener,
getDataListener,
getDataSource,
getDataSource,
getID,
getRunningID,
getSourceData,
getSourceVariables,
isAutoRefresh,
isClockRunning,
makeDataConnection,
pause,
pausingClock,
removeDataListener,
removeDataSource,
reset,
reverse,
setAutoRefresh,
setClockContinous,
setClockCycle,
setClockOneShot,
setClockTime,
setConnectionBlock,
setConnectionListener,
setConnectionSmoothing,
setConnectionSource,
setConnectionStride,
setDefault,
setDt,
setFPS,
setRunningID,
setRunningID,
setTimeContinuous,
setTimeCycle,
setTimeOneShot,
startClock,
stepClock,
stepTime,
stepTimeBack,
stepTimeForward,
stopClock,
stoppingClock,
updateDataConnection,
updateDataConnections,
useMasterClock |
| Methods inherited from class java.applet.Applet |
getAppletContext,
getAudioClip,
getAudioClip,
getCodeBase,
getDocumentBase,
getImage,
getImage,
getLocale,
getParameter,
isActive,
newAudioClip,
play,
play,
resize,
resize,
setStub,
showStatus |
| Methods inherited from class java.awt.Panel |
addNotify |
| Methods inherited from class java.awt.Container |
add,
add,
add,
add,
add,
addContainerListener,
addImpl,
countComponents,
deliverEvent,
doLayout,
findComponentAt,
findComponentAt,
getAlignmentX,
getAlignmentY,
getComponent,
getComponentAt,
getComponentAt,
getComponentCount,
getComponents,
getInsets,
getLayout,
getMaximumSize,
getMinimumSize,
getPreferredSize,
insets,
invalidate,
isAncestorOf,
layout,
list,
list,
locate,
minimumSize,
paint,
paintComponents,
paramString,
preferredSize,
print,
printComponents,
processContainerEvent,
processEvent,
remove,
remove,
removeAll,
removeContainerListener,
removeNotify,
setCursor,
setFont,
setLayout,
update,
validate,
validateTree |
| Methods inherited from class java.awt.Component |
action,
add,
addComponentListener,
addFocusListener,
addInputMethodListener,
addKeyListener,
addMouseListener,
addMouseMotionListener,
addPropertyChangeListener,
addPropertyChangeListener,
bounds,
checkImage,
checkImage,
coalesceEvents,
contains,
contains,
createImage,
createImage,
disable,
disableEvents,
dispatchEvent,
enable,
enable,
enableEvents,
enableInputMethods,
firePropertyChange,
getBackground,
getBounds,
getBounds,
getColorModel,
getComponentOrientation,
getCursor,
getDropTarget,
getFont,
getFontMetrics,
getForeground,
getGraphics,
getHeight,
getInputContext,
getInputMethodRequests,
getLocation,
getLocation,
getLocationOnScreen,
getName,
getParent,
getPeer,
getSize,
getSize,
getToolkit,
getTreeLock,
getWidth,
getX,
getY,
gotFocus,
handleEvent,
hasFocus,
hide,
imageUpdate,
inside,
isDisplayable,
isDoubleBuffered,
isEnabled,
isFocusTraversable,
isLightweight,
isOpaque,
isShowing,
isValid,
isVisible,
keyDown,
keyUp,
list,
list,
list,
location,
lostFocus,
mouseDown,
mouseDrag,
mouseEnter,
mouseExit,
mouseMove,
mouseUp,
move,
nextFocus,
paintAll,
postEvent,
prepareImage,
prepareImage,
printAll,
processComponentEvent,
processFocusEvent,
processInputMethodEvent,
processKeyEvent,
processMouseEvent,
processMouseMotionEvent,
remove,
removeComponentListener,
removeFocusListener,
removeInputMethodListener,
removeKeyListener,
removeMouseListener,
removeMouseMotionListener,
removePropertyChangeListener,
removePropertyChangeListener,
repaint,
repaint,
repaint,
repaint,
requestFocus,
reshape,
setBackground,
setBounds,
setBounds,
setComponentOrientation,
setDropTarget,
setEnabled,
setForeground,
setLocale,
setLocation,
setLocation,
setName,
setSize,
setSize,
setVisible,
show,
show,
size,
toString,
transferFocus |
| Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
| Constructor Detail |
public Data()
| Method Detail |
public java.lang.String getParameter(java.lang.String key,
java.lang.String def)
public void init()
public void start()
public void stop()
public void destroy()
public java.lang.String getAppletInfo()
public java.lang.String[][] getParameterInfo()
public void addData(edu.davidson.tools.SDataSource ds,
int id,
double[] x,
double[] y)
ds - SDataSource (obtained from the source getID functionid - data set idx[] - array of x valuesy[] - array of y valuesSApplet.getID()
public void addDatum(edu.davidson.tools.SDataSource ds,
int id,
double x,
double y)
ds - SDataSource (obtained from the source getID functionid - data set idx - x value of data pointy - y value of data pointSApplet.getID()
public int addDataSet(java.lang.String func,
int id)
func - string containing name of the JavaScript functionid - identification of data set associated with this functionpublic void callJavaScript(boolean val)
public void clearSeries(int id)
id - identification of the data set to be clearedpublic void deleteSeries(int id)
id - identification of the data set to be clearedpublic int getNumberPoints(int id)
id - data set identificationpublic edu.davidson.tools.SApplet getOwner()
public void setBackgroundColor(java.lang.String rgb)
rgb - this string is converted into a 24-bit integer that defines the colorpublic void setLabelFont(java.awt.Font fnt)
public void setLabelFormat(int nbrLength,
int nbrDecimal)
nbrLength - total number of characters in number including sign and decimal pointnbrDecimal - total number of decimal places displayed
public void setLabelSize(int wid,
int ht)
wid - width in pixelsht - height in pixelspublic void setLabelText(java.lang.String val)
public void setOwner(edu.davidson.tools.SApplet owner)
|
Chemistry AppletsDavid N. Blauch |
||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||