Overview | Package | Class | Tree | Deprecated | Index | Help
| ContactCenters V. 0.9.9.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## umontreal.iro.lecuyer.contactcenters.expdelay
Interface WaitingTimePredictor

All Known Implementing Classes:
  ExpectedDelayPredictor, ExpectedDelayPredictorHQ, ExpectedDelayWithAbandonPredictor, HeadOfQueuePredictor, LastWaitingTimePerQueuePredictor, LastWaitingTimePredictor, MeanNLastWaitingTimePerQueuePredictor, MeanNLastWaitingTimePredictor

    public interface WaitingTimePredictor

Represents a heuristic that can predict the waiting time of a contact depending on the system's state. Such predictions can be used, e.g., for routing, altering patience time, etc. A predictor can have an associated router which is used to obtain system state necessary for predictions. It can also register listeners in order to receive additional information. The method `getWaitingTime(Contact)` is used to get a prediction of the waiting time for a given contact waiting in any queue. The method `getWaitingTime(Contact,WaitingQueue)`, on the other hand, gives a prediction of the waiting time for a contact waiting in a specific queue.

Method Summary
`Router` | `getRouter()` Returns a reference to the router associated with this predictor.
`double` | `getWaitingTime(Contact contact)` Returns a prediction of the waiting time of contact `contact` waiting in any queue.
`double` | `getWaitingTime(Contact contact, WaitingQueue queue)` Returns a prediction of the waiting time for the given contact `contact` conditional on the contact joining the waiting queue `queue`.
`void` | `init()` Resets any internal variable of this predictor.
`void` | `setRouter(Router router)` Sets the router associated with this predictor to `router`.

Method Detail

### getRouter

    Router getRouter()

  Returns a reference to the router associated with this predictor. By default, this returns `null` since no router is bound to a newly-constructed predictor. A router is associated with a predictor using the `setRouter(Router)` method.

  Returns:
    a reference to the currently associated router.

### setRouter

    void setRouter(Router router)

  Sets the router associated with this predictor to `router`. When `router` is non-`null`, this method can also register any listener required to make the predictions. If the router associated with a predictor is changed, the predictor should unregister any listener associated with the previous router.

  Parameters:
    `router` - the new router.

### init

    void init()

  Resets any internal variable of this predictor.

### getWaitingTime

    double getWaitingTime(Contact contact)

  Returns a prediction of the waiting time of contact `contact` waiting in any queue. This method returns `Double.NaN` if it cannot make a prediction for the given contact.

  Parameters:
    `contact` - the contact for which we need a prediction.
  Returns:
    the global waiting time.

### getWaitingTime

    double getWaitingTime(Contact contact,
                          WaitingQueue queue)

  Returns a prediction of the waiting time for the given contact `contact` conditional on the contact joining the waiting queue `queue`. This method returns `Double.NaN` if it cannot make a prediction for the given contact, or the given waiting queue.

  Parameters:
    `contact` - the contact for which a delay is predicted.
    `queue` - the target waiting queue.
  Returns:
    the predicted delay.

Overview | Package | Class | Tree | Deprecated | Index | Help
| ContactCenters V. 0.9.9.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

To submit a bug or ask questions, send an e-mail to Richard Simard.