Package | Description |
---|---|
myhw3.command | |
myhw3.data |
Modifier and Type | Field and Description |
---|---|
(package private) java.util.Stack<Command> |
CommandHistoryObj.redoStack |
(package private) java.util.Stack<Command> |
CommandHistoryObj.undoStack |
Modifier and Type | Method and Description |
---|---|
(package private) Command |
CommandHistoryObj.topRedoCommand() |
(package private) Command |
CommandHistoryObj.topUndoCommand() |
Modifier and Type | Method and Description |
---|---|
void |
CommandHistory.add(Command cmd)
Add command
undoable and clear redoable . |
void |
CommandHistoryObj.add(Command cmd) |
Modifier and Type | Class and Description |
---|---|
(package private) class |
CmdAdd
Implementation of command to add or remove inventory.
|
(package private) class |
CmdClear
Implementation of command to clear the inventory.
|
(package private) class |
CmdIn
Implementation of command to check in a video.
|
(package private) class |
CmdOut
Implementation of command to check out a video.
|
Modifier and Type | Method and Description |
---|---|
static Command |
Data.newAddCmd(Inventory inventory,
Video video,
int change)
Returns a command to add or remove copies of a video from the inventory.
|
static Command |
Data.newClearCmd(Inventory inventory)
Returns a command to remove all records from the inventory.
|
static Command |
Data.newInCmd(Inventory inventory,
Video video)
Returns a command to check in a video.
|
static Command |
Data.newOutCmd(Inventory inventory,
Video video)
Returns a command to check out a video.
|