A B C E F G H I L M N P R S T U W

A

actionPerformed(ActionEvent) - Method in class ScrabbleView
The method which takes care of all events handled
actionPerformed(ActionEvent) - Method in class SquareListener
 
addMove(Move) - Method in class GameMoves
 
addMove(Move) - Method in class Scrabble
 
addTile(Tile) - Method in class Bag
Adds a tile to the bag
addTile(Tile, int, int) - Method in class Board
Adds a letter to the board, returns -1 if unsuccessful Otherwise, it adds the letter and returns the amount of points gained.
addTile(Tile) - Method in class Player
Adds a tile to the player's hand
asString() - Method in class Word
 

B

Bag - Class in <Unnamed>
A simple stack holding all the Tiles
Bag() - Constructor for class Bag
 
Bag(Tile[]) - Constructor for class Bag
Initializes the bag fom an array of Tiles
Bag(ArrayList<Tile>) - Constructor for class Bag
Initializes the bag from an ArrayList of Tiles
Board - Class in <Unnamed>
 
Board() - Constructor for class Board
 
Board(String) - Constructor for class Board
 
BoardPanel - Class in <Unnamed>
 
BoardPanel(Board, SquareListener) - Constructor for class BoardPanel
 

C

calculatePoints(ArrayList<Square>) - Method in class Board
Takes in a ArrayList of the location of the new pieces
calculatePoints(int, int) - Method in class Board
Calculates the amount of points gained by the recent placement of the piece at [row, col].
calculatePoints() - Method in class Square
Calculate the score of this square.
checkWord(Word) - Method in class Board
Checks whether the word passed in exists in the dictionary
clear() - Method in class Bag
Clears all the Tiles from the bag
clone() - Method in class Player
Creates a deep copy
clone() - Method in class Tile
 
compare(Player, Player) - Method in class Player
Implementation of Comparator - compares based on name
compare(Tile, Tile) - Method in class Tile
 
compareTo(Player) - Method in class Player
Implementation of Comparable compares based on score
compareTo(Tile) - Method in class Tile
 
compareTo(Word) - Method in class Word
 
createBag() - Static method in class Bag
Creates the scabble set of Tiles.

E

empty() - Method in class Bag
Returns true if the bag is empty, otherwise false.
equals(Player) - Method in class Player
equals method
equals(Tile) - Method in class Tile
 
equals(Word) - Method in class Word
 

F

fromString(String) - Method in class Word
 

G

GameMoves - Class in <Unnamed>
 
GameMoves() - Constructor for class GameMoves
 
getBag() - Method in class Scrabble
 
getBoard() - Method in class Board
 
getBoard() - Method in class BoardPanel
 
getBoard() - Method in class Scrabble
 
getBoard() - Method in class ScrabbleView
 
getCurrentPlayer() - Method in class ScrabbleView
Get the current player
getCurrentTurn() - Method in class Scrabble
 
getDirection() - Method in class ScrabbleView
 
getFirstSquare() - Method in class ScrabbleView
GET/SET for has the first square been chosen? PROJECT 5
getGameMoves() - Method in class Scrabble
 
getHand() - Method in class Player
 
getHorizontalWord(int, int) - Method in class Board
Returns a Word, the horizontal word begining at [row,col]
getHorizontalWordSquares(int, int) - Method in class Board
Returns the list of squares making up the word beginning at row, col [word]
getHorizontalWordStart(int, int) - Method in class Board
Returns [x,y] point of the start of a word, [-1,-1] if invalid
getLetter() - Method in class Tile
 
getMoves() - Method in class Scrabble
 
getName() - Method in class Player
 
getNewTiles() - Method in class Move
 
getOrientation() - Method in class Move
 
getPlayerNumber() - Method in class Move
 
getPlayers() - Method in class Scrabble
 
getPosition() - Method in class Move
 
getPosition() - Method in class Square
 
getPosition() - Method in class Tile
 
getScore() - Method in class Move
 
getScore() - Method in class Player
 
getScore() - Method in class Tile
 
getSecondSquare() - Method in class ScrabbleView
 
getSelectedButton() - Method in class ScrabbleView
Get the selected button
getSelectedHandButtons() - Method in class ScrabbleView
Returns the list of handbuttons selected in the current move
getSelectedSquares() - Method in class ScrabbleView
Returns the list of squares selected in the current move
getTile() - Method in class Bag
gets a random Tile
getTile() - Method in class HandButton
 
getTile() - Method in class Square
 
getTiles() - Method in class Bag
 
getTiles() - Method in class Word
 
getType() - Method in class Square
 
getVerticalWord(int, int) - Method in class Board
Returns a ArrayList, the vertical word begining at [row,col]
getVerticalWordSquares(int, int) - Method in class Board
Returns the list of squares making up the word beginning at row, col [vertical]
getVerticalWordStart(int, int) - Method in class Board
Returns [x,y] point of the start of a word, [-1,-1] if invalid
getWords() - Method in class Move
 
getX() - Method in class Position
 
getY() - Method in class Position
 

H

HandButton - Class in <Unnamed>
 
HandButton() - Constructor for class HandButton
 
HandButton(Tile) - Constructor for class HandButton
 
hasTile() - Method in class Square
 

I

init() - Method in class Board
 
initTiles(Tile[]) - Method in class Bag
Fills the bag with a new set of Tiles
isOccupied() - Method in class Square
 
isSelectable() - Method in class Square
 

L

LetterMap - Class in <Unnamed>
 
LetterMap() - Constructor for class LetterMap
 

M

main(String[]) - Static method in class ScrabbleView
 
makeBoard() - Method in class Board
Reads the board from a file and inits the board attribute.
Move - Class in <Unnamed>
 
Move(Integer, ArrayList<Word>, Position, Character, ArrayList<Tile>, Integer) - Constructor for class Move
 

N

nextTurn() - Method in class Scrabble
 

P

parseScrabbleData(String[]) - Method in class ScrabbleData
Parses the Array returned from readFromFile(..)
Player - Class in <Unnamed>
The Player class - represents each player
Player() - Constructor for class Player
Create player
Player(String, SLL<Tile>) - Constructor for class Player
 
Position - Class in <Unnamed>
A position on a board x = row y = column
Position() - Constructor for class Position
 
Position(int, int) - Constructor for class Position
 

R

readFromFile(String) - Method in class ScrabbleData
Reads from a file
refresh(Board, SquareListener) - Method in class BoardPanel
 
removeTile(Tile) - Method in class Player
removes a tile from the player's hand Returns true if tile exists and was removed Returns false if tile not found

S

Scrabble - Class in <Unnamed>
The main Scrabble class.
Scrabble(Bag, Board, Player[], ArrayList<Move>) - Constructor for class Scrabble
 
Scrabble(Bag, Board, Player[], ArrayList<Move>, int) - Constructor for class Scrabble
 
ScrabbleData - Class in <Unnamed>
 
ScrabbleData(ScrabbleView) - Constructor for class ScrabbleData
 
ScrabbleView - Class in <Unnamed>
The application's main frame.
ScrabbleView() - Constructor for class ScrabbleView
Constructor
setBag(Bag) - Method in class Scrabble
 
setBoard(Square[][]) - Method in class Board
 
setBoard(Board) - Method in class BoardPanel
 
setBoard(Board) - Method in class Scrabble
 
setCurrentTurn(int) - Method in class Scrabble
 
setDirection(int) - Method in class ScrabbleView
 
setFirstSquare(boolean) - Method in class ScrabbleView
 
setHand(SLL<Tile>) - Method in class Player
 
setLetter(Character) - Method in class Tile
 
setName(String) - Method in class Player
 
setNewTiles(ArrayList<Tile>) - Method in class Move
 
setOccupied(boolean) - Method in class Square
 
setOrientation(Character) - Method in class Move
 
setPlayer(Player[]) - Method in class Scrabble
 
setPlayerNumber(Integer) - Method in class Move
 
setPosition(Position) - Method in class Move
 
setPosition(Position) - Method in class Square
 
setPosition(Position) - Method in class Tile
 
setScore(Integer) - Method in class Move
 
setScore(Integer) - Method in class Player
 
setScore(Integer) - Method in class Tile
 
setSecondSquare(boolean) - Method in class ScrabbleView
 
setSelectable(boolean) - Method in class Square
 
setSelectedButton(HandButton) - Method in class ScrabbleView
set the selected button
setTile(Tile) - Method in class HandButton
 
setTile(Tile) - Method in class Square
 
setTiles(Stack<Tile>) - Method in class Bag
 
setTiles(ArrayList<Tile>) - Method in class Bag
 
setTiles(ArrayList<Tile>) - Method in class Word
 
setType(SquareType) - Method in class Square
 
setWords(ArrayList<Word>) - Method in class Move
 
setX(int) - Method in class Position
 
setY(int) - Method in class Position
 
shake() - Method in class Bag
Shake the bag!
Square - Class in <Unnamed>
 
Square() - Constructor for class Square
 
Square(Position, Tile, SquareType, boolean) - Constructor for class Square
 
SquareListener - Class in <Unnamed>
 
SquareListener(ScrabbleView) - Constructor for class SquareListener
 
swapTile(Tile) - Method in class Bag
Put back a Tile, shake the bag, and get a new Tile

T

Tile - Class in <Unnamed>
 
Tile() - Constructor for class Tile
Creates the default letter '-' with a score value of 0.
Tile(Character) - Constructor for class Tile
Inits the letter and gives a score of 1
Tile(Character, Integer) - Constructor for class Tile
 
Tiles - Variable in class Bag
 
toString() - Method in class Bag
Prints the contents of the bag
toString() - Method in class Board
 
toString() - Method in class Move
 
toString() - Method in class Player
 
toString() - Method in class Position
 
toString() - Method in class Square
 
toString() - Method in class Tile
 
toString() - Method in class Word
 

U

undo() - Method in class SquareListener
Undo the last tile placement
undoMoves(Word, Scrabble) - Method in class GameMoves
Undoes a move which has the first occurrence of the word passed in (and also undoes all the moves performed after that)
updateBoard() - Method in class ScrabbleView
Updates the Board Panel
updateHandButtons() - Method in class ScrabbleView
Updates the text on the hand buttons
updateScores() - Method in class ScrabbleView
Updates the scores panel

W

Word - Class in <Unnamed>
 
Word() - Constructor for class Word
 
Word(ArrayList<Tile>) - Constructor for class Word
 
WordsExist(ArrayList<String>) - Static method in class Board
Checks to see if any of the words in the list are actual words.
writeToFile(Scrabble, String) - Method in class ScrabbleData
Writes the Scrabble info to a file

A B C E F G H I L M N P R S T U W