airline
Class CustomerSession

java.lang.Object
  extended by airline.CustomerSession
All Implemented Interfaces:
UserSession

public class CustomerSession
extends Object
implements UserSession

Manages the flow of control for a session with a registered Customer.

Author:
Michael goldwasser

Field Summary
private  Connection connect
          The Connection instance managing the front-end interactions for this session.
private  Customer customer
          The Customer instance associated with this session.
 
Constructor Summary
CustomerSession(Customer customer, Connection connect)
          Instantiates a new session for the given Customer and the given front-end Connection.
 
Method Summary
 void mainDialog()
          The main menu is first presented to a Customer immediately after logging in.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

connect

private Connection connect
The Connection instance managing the front-end interactions for this session.


customer

private Customer customer
The Customer instance associated with this session.

Constructor Detail

CustomerSession

public CustomerSession(Customer customer,
                       Connection connect)
Instantiates a new session for the given Customer and the given front-end Connection. The constructor does not begin any interactions. Those should typically be started by calling mainDialog().

Parameters:
customer - The Customer instance associated with this session
connect - The Connection instance managing the front-end interactions for this session
Method Detail

mainDialog

public void mainDialog()
The main menu is first presented to a Customer immediately after logging in. It offers choices for managing existing reservations or creating new ones.

Specified by:
mainDialog in interface UserSession