Adds a customer in system.
PRECONDITION:
Customer must have the following information set already:
- call-in time
- pickup address
- pickup time
- destination address
POSTCONDITION: customer's information is set
scheduler now has customer within domain
datastore knows of ride request
Adds a customer in system.
PRECONDITION:
Customer must have the following information set already:
- call-in time
- pickup address
- pickup time
- destination address
POSTCONDITION: customer's information is set
scheduler now has customer within domain
datastore knows of ride request
Adds a customer in system.
PRECONDITION:
Customer must have the following information set already:
- call-in time
- pickup address
- pickup time
- destination address
POSTCONDITION: customer's information is set
scheduler now has customer within domain
datastore knows of ride request
Inserts data representing a polygon's vertex, given 2 integers representing the polygon:
Zone/polygon ID ( >= 0 ), the vertex identifier ( > 0 ), and 2 doubles representing
an x coordinate and a y coordinate.
Stores a Customer object just after it has been created:
it will not have a cab yet so it is a "ride request," but should still
have all destination information.
Attaches the Reservation Info Panel to the customer info panel, so
that actions on the customer info panel can be displayed in the
Reservation Info Panel.
Robot class
Notes:
0,0 upper left hand corner of screen
x runs horizontally across screen, positive towards right
y runs vertically across screen, positive down screen
seem to be independent of screen resolution
Cancels scheduled cab, assumes customer field in cab is set
scheduler calls when cancelled customer not found in waiting customer queue
and msg needs to be relayed to cab console, cab will be placed back into front of zone which
cab is found in
assume customer's cab field will be set elsewhere (by scheduler)
PRECONDITION: customer corresponding to cab has been canceled
POSTCONDITION: cab is still in busy cab list, everything but zone is set correctly
Cancels scheduled cab, assumes customer field in cab is set
scheduler calls when cancelled customer not found in waiting customer queue
and msg needs to be relayed to cab console, cab will be placed back into front of zone which
cab is found in
assume customer's cab field will be set elsewhere (by scheduler)
PRECONDITION: customer corresponding to cab has been canceled
POSTCONDITION: cab is still in busy cab list, everything but zone is set correctly
Cancels scheduled cab, assumes customer field in cab is set
scheduler calls when cancelled customer not found in waiting customer queue
and msg needs to be relayed to cab console, cab will be placed back into front of zone which
cab is found in
assume customer's cab field will be set elsewhere (by scheduler)
PRECONDITION: customer corresponding to cab has been canceled
POSTCONDITION: cab is still in busy cab list, everything but zone is set correctly
Constructor - uses default (hard-coded in this file) name, password, and database driver
to create a database connection object and database statement object.
fillDataSet - given a Vector of Vectors (all of which are the same size,)
this method will use those vectors to fill out the dataset of a manager report
object thus allowing for easy data insertion
PRECONDITION: method caller provides as a parameter a Vector of Vectors
where each Vector inside the parameter is of the same size.
Given an integer representing a Zone/polygon identifier, this method returns all
the polygon vertex data associated with that polygon in the form of a vector of
polygon vertex objects that contain the desired data
Returns all arriving cabs to specified zone;
to be used when no cabs available in desired zone.
Assumes that the customer field in the cab is set correctly
Returns all arriving cabs to specified zone;
to be used when no cabs available in desired zone.
Assumes that the customer field in the cab is set correctly
getNumDispatcherOverrides - given a String representing a dispatcher's name, this method
returns an integer representing the number of dispatcher overrides present in the db corresponding to
that dispatcher
**NOTE** to effectively turn off the "date" arguments simply pass in 2 of the same date objects.
Passes ManagerReport request from ManagerUI to DataStore
Given an enumerated type of report, this method will return a Report
designed for a manager of the cab company
ModelRMIInterface
Public Interface to define RMI
THIS INTERFACE IS FOR THE DISPATHCHER UI -
PLEASE TELL US WHAT METHODS YOU NEED!!!
PLEASE EMAIL INTERFACE CHANGE REQUESTS TO MIKAM TRIBE:
margaux, ianli, kkchen, alexcho, meilye
registers the cab in the model if cab_id and driver_id are valid (in database)
PRECONDITION: both cab and driver identified by cab_id and driver_id registers for the first time.
POSTCONDITION: a cab object corresponding to the cab console has been created and placed in its
respective zone in the model
registers the cab in the model if cab_id and driver_id are valid (in database)
PRECONDITION: both cab and driver identified by cab_id and driver_id registers for the first time.
POSTCONDITION: a cab object corresponding to the cab console has been created and placed in its
respective zone in the model
registers the cab in the model if cab_id and driver_id are valid (in database)
PRECONDITION: both cab and driver identified by cab_id and driver_id registers for the first time.
POSTCONDITION: a cab object corresponding to the cab console has been created and placed in its
respective zone in the model
For Scheduler
Relays ride request from scheduler to cab console
Responsible only for relaying messages
PRECONDITION: valid cab id
cab currently in the model
POSTCONDITION: none
For Scheduler
Relays ride request from scheduler to cab console
Responsible only for relaying messages
PRECONDITION: valid cab id
cab currently in the model
POSTCONDITION: none
For Scheduler
Relays ride request from scheduler to cab console
Responsible only for relaying messages
PRECONDITION: valid cab id
cab currently in the model
POSTCONDITION: none
Moves the temporary customer info in the rideRequest Table into the Customers table and logs the
specific ride information into the rideLog table, given a Cab object.
Unit test helper method setup an instance in time in which there are busy cabs in the "world."
This function will create an instance in which:
cab1 has picked up cust1
cab2 has picked up cust2
cust0 and cust3 are waiting
PRECONDITIONS: test_setupInitialWorld was just called.
Unit test helper method to setup an instance in time in which there are customers waiting.
This function will create an instance in which:
cust2 has been scheduled.
Updates the ridelog and customer tables, given a cab object representing the previous
state of a cab-ride-assignment and a cab object representing the new state of a
cab-ride-assignment.
For Cab Console:
Called after console updates referenced cab object, this method triggers necessary
model updates
Case 0: customer dropped off
Case 2: customer has been picked up
Case 3: customer has canceled and cab has been canceled
PRECONDITION: cab console has changed its status and needs to be updated in the model
case 0: cab is busy
case 2: none
case 3: cab has been emptied of its customer and is in the busy cab list
POSTCONDITION: case 0: cab is waiting in its appropriate zone
case 2: pickup time for customer in database has been updated
case 3: cab waiting at front of zone's cab list
For Cab Console:
Called after console updates referenced cab object, this method triggers necessary
model updates
Case 0: customer dropped off
Case 2: customer has been picked up
Case 3: customer has canceled and cab has been canceled
PRECONDITION: cab console has changed its status and needs to be updated in the model
case 0: cab is busy
case 2: none
case 3: cab has been emptied of its customer and is in the busy cab list
POSTCONDITION: case 0: cab is waiting in its appropriate zone
case 2: pickup time for customer in database has been updated
case 3: cab waiting at front of zone's cab list
For Cab Console:
Called after console updates referenced cab object, this method triggers necessary
model updates
Case 0: customer dropped off
Case 2: customer has been picked up
Case 3: customer has canceled and cab has been canceled
PRECONDITION: cab console has changed its status and needs to be updated in the model
case 0: cab is busy
case 2: none
case 3: cab has been emptied of its customer and is in the busy cab list
POSTCONDITION: case 0: cab is waiting in its appropriate zone
case 2: pickup time for customer in database has been updated
case 3: cab waiting at front of zone's cab list