A B C D F G H I J M N O P R S T U V W

A

Accelerator - interface Spirograph.Accelerator.
The students will some simple statements that the CodeBox will write to a file.
AccelHandler - class Spirograph.AccelHandler.
This class contains a Thread that continuously prompts the user's class for an acceleration and passes this information on to an instance of DotPanel.
AccelHandler(Accelerator, DotPanel, Coord, Coord) - Constructor for class Spirograph.AccelHandler
Creates a new AccelHandler.
ACCELMODE - Static variable in class Spirograph.AccelHandler
Acceleration control mode
act(double, double, double, double, double) - Method in class Spirograph.Dummy
Just returns 0
act(double, double, double, double, double) - Method in interface Spirograph.Accelerator
 
act(double, double, double, double, double) - Method in class Spirograph.VertRule
 
act(double, double, double, double, double) - Method in class Spirograph.HorizRule
 
actionPerformed(ActionEvent) - Method in class Spirograph.SetVListener
 
actionPerformed(ActionEvent) - Method in class Spirograph.CodeMerger
Creates a .java file containing the rules and fields written by the students, then compiles it.
addGrav(int, int) - Method in class Spirograph.DotPanel
 
addListener(ActionListener) - Method in class Spirograph.AdvEnv
 
addListeners(ActionListener, ActionListener, ActionListener, ActionListener) - Method in class Spirograph.ResetMenu
 
AdvEnv - class Spirograph.AdvEnv.
This class creates the window that appears when the user clicks on the Advanced Environment Options button.
AdvEnv(TextField, TextField, SetPosGravListener, DotPanel) - Constructor for class Spirograph.AdvEnv
Constructs the Advanced Environment Features menu with a default font.
AdvEnv(TextField, TextField, SetPosGravListener, DotPanel, Font) - Constructor for class Spirograph.AdvEnv
Specifies rules for switching the DotPanel to a circular mode, switching the border behavior between wraparound and bounce, setting position, velocity, and acceleration, and for closing the window.

B

BALLSIZE - Static variable in class Spirograph.Spirograph
Size of the dot as it will appear in the GUI.

C

CodeBox - class Spirograph.CodeBox.
This class pops up the Code editing area.
CodeBox(TextArea, TextArea, TextArea, TextArea, CodeMerger, CodeMerger, AccelHandler, AccelHandler) - Constructor for class Spirograph.CodeBox
Construct a new CodeBox.
CodeBox(TextArea, TextArea, TextArea, TextArea, CodeMerger, CodeMerger, AccelHandler, AccelHandler, Font) - Constructor for class Spirograph.CodeBox
Construct a CodeBox.
CodeMerger - class Spirograph.CodeMerger.
This class implements a listener that is added to the "Load Horizontal Code." and "Load Vertical Code" buttons on the Code Box.
CodeMerger(String, TextArea, TextArea, AccelHandler, AccelHandler) - Constructor for class Spirograph.CodeMerger
 
Coord - class Spirograph.Coord.
This class holds information regarding one dimension of the ball.
Coord() - Constructor for class Spirograph.Coord
 
copyFiles(String, String) - Static method in class Spirograph.SpiroUtils
 
createAccel(String) - Static method in class Spirograph.SpiroUtils
This method reads in a file, creates an Object from that class and casts it to an Accelerator.
CUR - Static variable in class Spirograph.SpiroUtils
 
curHeight() - Method in class Spirograph.DotPanel
 
curWidth() - Method in class Spirograph.DotPanel
 

D

DEFAULTFONT - Static variable in class Spirograph.Spirograph
Problem set wide default font.
delFile(String) - Static method in class Spirograph.SpiroUtils
 
dist(double, double, double, double) - Static method in class Spirograph.Util
This method calculates the distance between any two points in 2D space
DotFrame - class Spirograph.DotFrame.
This class pops up the window for the Spirograph, creates all of the buttons and the DotPanel, and adds them.
DotFrame(AccelHandler, AccelHandler, DotPanel, Coord, Coord) - Constructor for class Spirograph.DotFrame
Takes care of GUI stuff.
DotFrame(AccelHandler, AccelHandler, DotPanel, Coord, Coord, Font) - Constructor for class Spirograph.DotFrame
Same as other constructor, except it sets the font rather than using a default.
DotPanel - class Spirograph.DotPanel.
This class keeps track of the coordinates of the Dot.
DotPanel(Coord, Coord) - Constructor for class Spirograph.DotPanel
 
Dummy - class Spirograph.Dummy.
The default accelerator Copyright (c) 1998 Massachusetts Institute of Technology
Dummy() - Constructor for class Spirograph.Dummy
 

F

flushGrav() - Method in class Spirograph.DotPanel
 
flushLines() - Method in class Spirograph.DotPanel
 
FOCUSSIZE - Static variable in class Spirograph.Spirograph
 

G

getAccel() - Method in class Spirograph.Coord
 
getBounce() - Method in class Spirograph.DotPanel
 
getCirc() - Method in class Spirograph.DotPanel
 
getMaxPos() - Method in class Spirograph.Coord
 
getMaxX() - Method in class Spirograph.DotPanel
 
getMaxY() - Method in class Spirograph.DotPanel
 
getMinimumSize() - Method in class Spirograph.DotPanel
 
getMode() - Method in class Spirograph.Coord
Determines the current mode of operation, either position, velocity, or accleration control.
getPos() - Method in class Spirograph.Coord
 
getPreferredSize() - Method in class Spirograph.DotPanel
 
getVel() - Method in class Spirograph.Coord
 
getWrap() - Method in class Spirograph.DotPanel
 
GRAV - Static variable in class Spirograph.SetPosGravListener
 
GRAV - Static variable in class Spirograph.Spirograph
 

H

HEIGHT - Static variable in class Spirograph.Spirograph
 
HorizRule - class Spirograph.HorizRule.
 
HorizRule() - Constructor for class Spirograph.HorizRule
 

I

inEllipse() - Method in class Spirograph.DotPanel
This is called by the AdvArg to see whether or not the ball is in the circle.
inEllipse(double, double, double, double) - Static method in class Spirograph.Util
This method calculate whether or not a given position is inside a given ellipse.
itemStateChanged(ItemEvent) - Method in class Spirograph.OneRuleListener
 

J

JAVAC - Static variable in class Spirograph.Util
 

M

Main - class Spirograph.Main.
Main is a wrapper for Spirograph.
main(String[]) - Static method in class Spirograph.Main
 
MARGINHEIGHT - Static variable in class Spirograph.MultiLabel
 
MARGINWIDTH - Static variable in class Spirograph.MultiLabel
 
MAXVEL - Static variable in class Spirograph.Spirograph
Maximum dot velocity allowed.
mouseClicked(MouseEvent) - Method in class Spirograph.SetPosGravListener
 
mouseEntered(MouseEvent) - Method in class Spirograph.SetPosGravListener
 
mouseExited(MouseEvent) - Method in class Spirograph.SetPosGravListener
 
mousePressed(MouseEvent) - Method in class Spirograph.SetPosGravListener
 
mouseReleased(MouseEvent) - Method in class Spirograph.SetPosGravListener
 
MultiLabel - class Spirograph.MultiLabel.
 
MultiLabel(String) - Constructor for class Spirograph.MultiLabel
 
MultiLabel(String, Font) - Constructor for class Spirograph.MultiLabel
 

N

nextStep(Vector, double) - Method in class Spirograph.Coord
Calculates the acceleration of the ball by taking the acceleration that was set and adding it to the combined accelerations resulting from each of the different gravitational fields.
NONE - Static variable in class Spirograph.SetPosGravListener
 

O

OneRuleListener - class Spirograph.OneRuleListener.
 
OneRuleListener(TextArea, TextArea, TextArea, TextArea, Button, Button, Checkbox, CodeMerger) - Constructor for class Spirograph.OneRuleListener
 

P

paint(Graphics) - Method in class Spirograph.MultiLabel
 
paint(Graphics) - Method in class Spirograph.DotPanel
 
paintBuf() - Method in class Spirograph.DotPanel
This method paints an off-screen image to be used for the double buffering. It adds the balls current position to the vector of Points, then reconstructs the balls path from the Points.
POS - Static variable in class Spirograph.SetPosGravListener
 
POSMODE - Static variable in class Spirograph.AccelHandler
Position control mode

R

readFile(String) - Static method in class Spirograph.Util
This method reads the specified file off of the current directory and returns it as a String.
ResetMenu - class Spirograph.ResetMenu.
 
ResetMenu() - Constructor for class Spirograph.ResetMenu
 
ResetMenu(Font) - Constructor for class Spirograph.ResetMenu
 
run() - Method in class Spirograph.DotPanel
 
run() - Method in class Spirograph.AccelHandler
Prompt the user's class for an accleration and pass the info on to our DotPanel.

S

setAccel(Accelerator) - Method in class Spirograph.AccelHandler
Changes the current Accelerator.
setAccel(double) - Method in class Spirograph.Coord
 
setBoth(boolean) - Method in class Spirograph.CodeMerger
This is used when the option to use the same rule for both the vertical and horizontal acceleration is selected
setBounce(boolean) - Method in class Spirograph.DotPanel
 
setCirc(boolean) - Method in class Spirograph.DotPanel
 
setMaxPos(double) - Method in class Spirograph.Coord
 
setMode(int) - Method in class Spirograph.SetPosGravListener
 
setMode(int) - Method in class Spirograph.DotPanel
 
setMode(int) - Method in class Spirograph.Coord
Sets the current mode.
setPos(double) - Method in class Spirograph.Coord
 
SetPosGravListener - class Spirograph.SetPosGravListener.
 
SetPosGravListener(Coord, Coord, DotPanel) - Constructor for class Spirograph.SetPosGravListener
 
setSize(int, int) - Method in class Spirograph.DotPanel
Called by the DotFrame whenever the DotFrame is resized
setValue(double) - Method in class Spirograph.Coord
 
setVel(double) - Method in class Spirograph.Coord
 
SetVListener - class Spirograph.SetVListener.
This class listens to the set velocity button in the AdvEnv Frame and sets the velocity of the dot with whatever text is in the TextArea.
SetVListener(TextField, TextField, Coord, Coord) - Constructor for class Spirograph.SetVListener
 
setWrap(boolean) - Method in class Spirograph.DotPanel
 
Spirograph - package Spirograph
 
Spirograph - class Spirograph.Spirograph.
This class handles a lot of the initialization for the Spirograph.
Spirograph(String, String) - Constructor for class Spirograph.Spirograph
Attempt to construct a new Spirograph with the given Accleration Handlers.
SpiroUtils - class Spirograph.SpiroUtils.
This class contained a bunch of Utilities that were specific to this problem set, but only one of them turned out to be neccesary.
SpiroUtils() - Constructor for class Spirograph.SpiroUtils
 
SUCCESS - Static variable in class Spirograph.Util
 

T

TIMESTEP - Static variable in class Spirograph.Spirograph
Minimum timestep for updates.

U

Util - class Spirograph.Util.
 
Util() - Constructor for class Spirograph.Util
 

V

VELMODE - Static variable in class Spirograph.AccelHandler
Velocity control mdde
VertRule - class Spirograph.VertRule.
 
VertRule() - Constructor for class Spirograph.VertRule
 

W

WIDTH - Static variable in class Spirograph.Spirograph
 
writeFile(String, String) - Static method in class Spirograph.Util
This routine takes a String and writes it to a file in the current directory.

A B C D F G H I J M N O P R S T U V W