public class TicketMachine
extends java.lang.Object
Constructor and Description |
---|
TicketMachine() |
Modifier and Type | Method and Description |
---|---|
void |
emptry()
Create a machine that issues tickets of the given price.
|
int |
getBalance()
Return the amount of money already inserted for the
next ticket.
|
int |
getPrice()
Return the price of a ticket.
|
void |
insertMoney(int amount)
Receive an amount of money in cents from a customer.
|
void |
printTicket()
Print a ticket.
|
void |
prompt() |
void |
showPrice() |
void |
TicketMachine2() |
public void emptry()
public int getBalance()
public int getPrice()
public void insertMoney(int amount)
public void printTicket()
public void prompt()
public void showPrice()
public void TicketMachine2()