Environment Plotter
A B C D E G H I L M N O P R S T

A

add(Locatable) - Method in class BoundedEnv
Adds a new object to this environment at the location it specifies.
allObjects() - Method in class BoundedEnv
Returns all the objects in this environment.

B

BACKGROUND_COLOR - Static variable in class EnvPlotterGUI
 
backgroundColorMenu - Variable in class EnvPlotterGUI
 
BoundedEnv - class BoundedEnv.
AP® Computer Science Marine Biology Simulation:
The BoundedEnv class models a bounded, two-dimensional, grid-like environment containing locatable objects.
BoundedEnv(int, int) - Constructor for class BoundedEnv
Constructs an empty BoundedEnv object with the given dimensions.

C

clearEnv() - Method in class EnvPlotter
Removes all objects from the environment.
col() - Method in class Location
Returns the column coordinate of this location.
colMajorFill(Color) - Method in class EnvPlotter
Fills in all the cells of the environment using a column-major traversal.
color() - Method in class ColorBlock
Gets color value for color block.
ColorBlock - class ColorBlock.
Environment-Based Applications:
A ColorBlock object encapsulates a color for a colored cell in an environment.
ColorBlock(Color, Environment, Location) - Constructor for class ColorBlock
Constructs a color block with the specified color.
compareTo(Object) - Method in class Location
Compares this location to other for ordering.
configure(BoundedEnv, SettableEnvDisplay) - Method in class EnvPlotter
Constructs an object that draws in the specified environment.

D

defineContent(Color, int, int, int) - Method in class EnvPlotterGUI
Defines contents of main window panel.
draw(String) - Method in class EnvPlotterGUI
Draws according to button pressed (called by action listener).
drawingColorMenu - Variable in class EnvPlotterGUI
 
drawingMethods - Variable in class EnvPlotterGUI
 

E

ENV_COLS - Static variable in class EnvPlotterGUI
 
ENV_ROWS - Static variable in class EnvPlotterGUI
 
envChoiceDialog - Variable in class EnvPlotterGUI
 
EnvPlotter - class EnvPlotter.
Environment-Based Applications:
The EnvPlotter class provides methods for drawing in an environment by placing color blocks in its cells.
EnvPlotter(BoundedEnv, SettableEnvDisplay) - Constructor for class EnvPlotter
Constructs an object that draws in the specified environment.
EnvPlotterApp - class EnvPlotterApp.
Environment-Based Applications:
The EnvPlotterApp class provides a main method for an application that draws by coloring cells in a bounded environment.
EnvPlotterApp() - Constructor for class EnvPlotterApp
 
EnvPlotterGUI - class EnvPlotterGUI.
Environment-Based Applications:
The EnvPlotterGUI class provides the graphical user interface for a program that draws in an environment by placing color blocks in its cells.
EnvPlotterGUI(String, int, int, int, int) - Constructor for class EnvPlotterGUI
Constructs the graphical user interface for the Environment Plotter program.
equals(Object) - Method in class Location
Indicates whether some other Location object is "equal to" this one.

G

getDrawingMethod(String) - Method in class EnvPlotterGUI
Gets the EnvPlotter drawing method associated with the specified button label.
getDrawingMethods() - Method in class EnvPlotterGUI
Builds a list of drawing methods that can be used by drawing buttons.

H

hashCode() - Method in class Location
Generates a hash code for this location (will not be tested on the Advanced Placement exam).
HIGHLIGHT_COLOR - Static variable in class EnvPlotterGUI
 

I

isEmpty(Location) - Method in class BoundedEnv
Determines whether a specific location in this environment is empty.
isValid(Location) - Method in class BoundedEnv
Verifies whether a location is valid in this environment.

L

Location - class Location.
AP® Computer Science Marine Biology Simulation:
A Location object represents the row and column of a location in a two-dimensional grid.
location() - Method in class ColorBlock
Gets color block's location.
Location(int, int) - Constructor for class Location
Constructs a Location object.

M

main(String[]) - Static method in class EnvPlotterApp
Starts the Environment Plotter program.
makeColorChooserPanel() - Method in class EnvPlotterGUI
Provides Color tools for choosing background color and drawing color.
makeControlPanel() - Method in class EnvPlotterGUI
Creates the control panel.
makeDrawingButtons() - Method in class EnvPlotterGUI
Creates a panel containing the drawing buttons based on the methods provided in the EnvPlotter class.
MIN_CELL_SIZE - Static variable in class EnvPlotterGUI
 

N

newEnv() - Method in class EnvPlotterGUI
Creates a new environment.
numCols() - Method in class BoundedEnv
Returns number of columns in the environment.
numObjects() - Method in class BoundedEnv
Returns the number of objects in this environment.
numRows() - Method in class BoundedEnv
Returns number of rows in the environment.

O

objectAt(Location) - Method in class BoundedEnv
Returns the object at a specific location in this environment.

P

plotter - Variable in class EnvPlotterGUI
 

R

recordMove(Locatable, Location) - Method in class BoundedEnv
Updates this environment to reflect the fact that an object moved.
remove(Locatable) - Method in class BoundedEnv
Removes the object from this environment.
resetEnv() - Method in class EnvPlotterGUI
Resets the environment.
row() - Method in class Location
Returns the row coordinate of this location.
rowMajorFill(Color) - Method in class EnvPlotter
Fills in all the cells of the environment using a row-major traversal.

S

setBackground() - Method in class EnvPlotterGUI
Changes the background color.

T

toString() - Method in class BoundedEnv
Creates a single string representing all the objects in this environment (not necessarily in any particular order).
toString() - Method in class Location
Represents this location as a string.

A B C D E G H I L M N O P R S T
Environment Plotter