1/49
Vocabulary flashcards covering GridWorld concepts, Java basics, and object-oriented terminology from the lecture notes.
Name | Mastery | Learn | Test | Matching | Spaced |
|---|
No study sessions yet.
GridWorld
A Java-based grid environment used in this course to learn object-oriented concepts, featuring Actors like Bugs and Rocks.
CSP-GridWorld.jar
The Java ARchive file that provides the GridWorld library for the project.
GridWorld Workspace.jcw
A GridWorld workspace file opened by JCreator to run a GridWorld project.
Workspace
An IDE area that organizes projects, files, and settings.
Active Project
The project currently selected for building and running.
BugRunner
A program/class that runs GridWorld bugs and demonstrates behaviors.
Grid location
A specific cell in the GridWorld grid, identified by a coordinate.
0-based indexing
Rows and columns are numbered starting at 0.
(row, column) pair
The representation used for a grid location in GridWorld.
Actor
A base class for things that exist on the GridWorld grid and may act.
Bug
A movable Actor subclass representing an insect in GridWorld.
Rock
A non-movable Actor subclass representing a rock obstacle.
Class
A blueprint for creating objects, defining data and behavior.
Object
An instance created from a class, with data and operations.
Parameter
Information required by a method to perform its task.
Argument
Actual data supplied to a method when it is called.
Method
A sequence of instructions an object follows to perform a task.
Return Value
The data produced by a method after it completes.
void
Return type indicating a method does not return a value.
H pattern
A design pattern formed with rocks/flowers for a BugRunner exercise.
java.awt.Color
Java class used to specify colors for objects in GridWorld.
Location
A class representing a grid position, typically with row and column.
Constructor
A special method used to create and initialize an object.
Overloaded
A method with multiple definitions that differ by parameter lists.
world.add(location, actor)
A GridWorld method to place an actor at a given location in the world.
Import
A statement to bring a class or package into scope for use.
Package
A namespace grouping related classes.
Java API
The official Java library of classes and interfaces provided by Oracle.
Accessor method
A method that retrieves data without changing the object.
Mutator method
A method that changes the object's data.
Simple Numeric Types
Primitive numeric types such as int and double.
int
Primitive type for whole numbers.
double
Primitive type for floating-point real numbers.
String
A sequence of characters used to represent text.
Concatenation
Joining two strings into one using the + operator.
length()
String method that returns the number of characters in the string.
Declaration
Statement that introduces a variable by its type and name.
Initialization
Assigning an initial value to a variable.
Assignment operator
The equals sign (=) used to assign a value to a variable.
Identifier
The name assigned to a variable, class, or method; must follow naming rules.
Reserved word
A Java keyword with a special meaning (e.g., int, public).
Java naming conventions
Standards: Class names in PascalCase; variables/methods in camelCase; constants in ALL_CAPS.
Comments
Annotations in code ignored by the compiler to aid human readers; types include single-line, multi-line, and Javadoc.
Javadoc
Documentation-style comments that can be extracted to create API docs; starts with /**.
File Heading
A 6-item Javadoc block at the top of a source file describing the class and collaborators.
Object variables
Variables that hold references to objects (memory addresses), not the objects themselves.
Importing a single class
Syntax: import PackageName.ClassName; to bring one class into scope.
Importing multiple classes from a package
Syntax: import PackageName.*; to bring all classes from a package into scope.
Strings (general)
String is a sequence of characters used to represent text.
Color constants
Predefined colors like Color.GREEN used to set object colors.