|
||||||||||
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 | +--com.jjt.utbeg.SeismicDesignExerciseApplet | +--com.jjt.utbeg.Applet1
The first JJT Applet for the UT exercises: source and receiver spacing
Inner classes inherited from class java.awt.Component |
Component.AWTTreeLock,
Component.NativeInLightFixer |
Field Summary | |
private Button |
depth1000Button
|
private Button |
depth2000Button
|
private Button |
depth3000Button
|
private Button |
depth4000Button
|
private Button |
depth5000Button
|
private Button |
depth6000Button
|
private Button |
depth7000Button
|
private Button |
depth8000Button
|
private NumericSpinner |
numberOfReceiverLinesSpinner
|
private NumericSpinner |
numberOfSourceLinesSpinner
|
private NumericSpinner |
receiverLineSpacingSpinner
|
private NumericSpinner |
receiverStationSpacingSpinner
|
private Button |
saveInputsButton
|
private NumericSpinner |
sourceLineSpacingSpinner
|
private NumericSpinner |
sourceStationSpacingSpinner
|
private NumericSpinner |
swathReferenceSizeSpinner
|
private SwathViewer |
swathViewer
|
private static double |
ZOOM_INCREMENT
The constant that the magnification factor is incremented or decremenent when the zoom in/out buttons are pressed. |
private Button |
zoomInButton
|
private Button |
zoomOutButton
|
Fields inherited from class com.jjt.utbeg.SeismicDesignExerciseApplet |
inputParametersAreValid,
insets,
parameterDisplayPanel,
parameterInputPanel,
parameters,
viewerPanel |
Fields inherited from class java.applet.Applet |
serialVersionUID,
stub |
Fields inherited from class java.awt.Panel |
base,
nameCounter,
serialVersionUID |
Fields inherited from class java.awt.Container |
component,
containerListener,
containerSerializedDataVersion,
dispatcher,
layoutMgr,
maxSize,
ncomponents,
serialVersionUID |
Constructor Summary | |
Applet1()
|
Method Summary | |
void |
actionPerformed(ActionEvent event)
This method is public as an implementation side-effect. |
private void |
addInfoLabel(Container panel,
GridBagLayout gridbag,
GridBagConstraints constraints,
Component label,
Component value)
Helper method to allow createAndLayoutDisplayComponents() to use a GridBagLayout, which is a nasty mess. |
private void |
createAndLayoutDisplayComponents()
Creates and places the components used to display the static values received into this exercise from previous exercises. |
private void |
createAndLayoutInputComponents()
Creates and places Components used for receiving parameter inputs from the human. |
private void |
createAndLayoutViewerComponents()
Creates and places Components used for viewing the swath image, including the "depth" buttons and zoom in/out buttons. |
protected java.net.URL |
getPostURL()
Returns the URL to submit this applet's parameters to the server. |
private String[] |
getSwathImageURLs()
Returns the URLs to be used to access the eight surface images for each depth. |
void |
init()
Initializes this Applet. |
private static void |
initSpinBox(NumericSpinner spinbox,
int from,
int to,
int by,
int initialValue)
Convenience method for initializing a Symantec spinner. |
void |
propertyChange(PropertyChangeEvent event)
This method is public as an implementation side-effect. |
protected void |
setInitialParameters()
Sets initial parameters for this exercise. |
protected String |
verifyInputParameters()
This method is called so that subclasses may verify that all their required parameters have been set. |
Methods inherited from class com.jjt.utbeg.SeismicDesignExerciseApplet |
getContentPane,
getInsets,
getNumericAppletParameter,
getParameterDisplayPanel,
getParameterInputPanel,
getParameters,
getViewerPanel,
inputParametersAreValid,
loadParameters,
readAppletParameterArray,
saveInputs |
Methods inherited from class java.applet.Applet |
destroy,
getAppletContext,
getAppletInfo,
getAudioClip,
getAudioClip,
getCodeBase,
getDocumentBase,
getImage,
getImage,
getLocale,
getParameter,
getParameterInfo,
isActive,
newAudioClip,
play,
play,
resize,
resize,
setStub,
showStatus,
start,
stop |
Methods inherited from class java.awt.Panel |
addNotify,
constructComponentName |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
registerNatives,
wait,
wait,
wait |
Field Detail |
private NumericSpinner sourceStationSpacingSpinner
private NumericSpinner receiverStationSpacingSpinner
private NumericSpinner sourceLineSpacingSpinner
private NumericSpinner receiverLineSpacingSpinner
private NumericSpinner numberOfSourceLinesSpinner
private NumericSpinner numberOfReceiverLinesSpinner
private NumericSpinner swathReferenceSizeSpinner
private Button saveInputsButton
private Button depth1000Button
private Button depth2000Button
private Button depth3000Button
private Button depth4000Button
private Button depth5000Button
private Button depth6000Button
private Button depth7000Button
private Button depth8000Button
private SwathViewer swathViewer
private Button zoomInButton
private Button zoomOutButton
private static final double ZOOM_INCREMENT
For example, when zoomInButton is pressed, swathViewer magnification is set to: currentMagnification + ZOOM_INCREMENT
Constructor Detail |
public Applet1()
Method Detail |
public void init()
Applets typically use init() instead of their usual constructors for creating Components.
private void createAndLayoutDisplayComponents()
private void addInfoLabel(Container panel, GridBagLayout gridbag, GridBagConstraints constraints, Component label, Component value)
This method adds two Label Components to a panel as a row in the GridBagLayout.
private void createAndLayoutInputComponents()
private void createAndLayoutViewerComponents()
protected String verifyInputParameters()
If this exercise (Applet) requires parameters to be set by previous exercises, then that will be validated here. Parameters are set in the UserParameters Object which can be retrieved by the getParameters() method.
null
if all required parameters are loaded.SeismicDesignExerciseApplet.getParameters()
protected void setInitialParameters()
Initial parameter values are usually based on input parameters which have been set in previous exercises. When this method is called, verifyInputParameters() has already been called, so all required input parameters can be assumed present.
verifyInputParameters()
private static void initSpinBox(NumericSpinner spinbox, int from, int to, int by, int initialValue)
spinbox
- the Symantec spin box to initializefrom
- the minimum value for the spinnerto
- the maximum value for the spinnerby
- the increment for the spinnerinitialValue
- the value to set for the spinnerprivate String[] getSwathImageURLs()
The URLs for the eight images should be placed in the HTML for this applet in this form:
public void propertyChange(PropertyChangeEvent event)
Called when a spin box is modified.
public void actionPerformed(ActionEvent event)
Called when a button is pushed.
protected java.net.URL getPostURL() throws java.net.MalformedURLException
The URL is probably actually an HTTP GET request, with the parameters attached as query arguments.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |