## EventMailboxService Requirements

ID | EventMailboxService Requirement | Section | Comments
| The register method has a single parameter of type long. This represents the lease duration for which use of the event mailbox is requested. The register method returns an object of type MailboxRegistration. | 10.5 | IF: EMSIFT, EMSRIFT Func: EMSFT EMSNSOT
| The value passed in as the requested lease duration must be a positive long value. This value represents the duration, in milliseconds, for use of the event mailbox. The special values defined in the Jini™ Distributed Leasing Specification, namely Lease.FOREVER and Lease.ANY, are also valid values. Lease.FOREVER represents a duration of maximum value while Lease.ANY represents a duration whose length is preferred and chosen by the event mailbox. |  | IF: EMSIFT EMSRIFT Func: EMSFT EMSNSOT
| In granting a lease to the caller of the register method, the event mailbox may grant either the requested duration or a shorter duration. |  | IF: EMSIFT EMSRIFT Func: EMSFT
| If the register method throws a RemoteException, then registration is not guaranteed to have happened. |  | Not testable
| Each successful invocation of the register method produces a new registration object. Thus, the register method is not idempotent. |  | IF: EMSIFT
| The getLease method takes no parameters and returns an object of type Lease. | 10.6 | IF: EMSIFT EMSRIFT Func: EMSFT
| The getListener method takes no parameters and returns an object of type RemoteEventListener. |  | IF: EMSRIFT Func: EMSFT EMSNSOT
| When the enableDelivery method is called, notification of the specified target listener object with the sequence of events collected by the event mailbox is commenced. |  | IF: EMSRIFT Func: EMSFT
| Making an enableDelivery method call while event delivery has already been enabled updates the target listener as specified in the forwarding target object parameter. |  | IF: EMSRIFT Func: EMSFT
| Any new events, arriving at the mailbox while the faucet is on, will be accumulated by the mailbox and eventually delivered to the current forwarding target object. |  | IF: Func: EMSFT
| An event that is successfully delivered to the forwarding target object is removed from event mailbox storage. |  | Not testable
| The event mailbox service delivers events to the forwarding target object by calling its notify method. ... If this call throws a NoSuchObjectException, event delivery is halted. |  | Func: EMSNSOT
| The process of sending events continues until the event mailbox has either exhausted its supply of collected events from storage ... |  | Func: EMSFT
| The process of sending events continues until the event mailbox ... is instructed to halt delivery. |  | Func: EMSFT
| Calling enableDelivery with a null forwarding target object halts event delivery. |  | IF: EMSRIFT Func: EMSFT
| Calling the disableDelivery method instructs the mailbox to halt the delivery of events. |  | IF: EMSRIFT Func: EMSFT
| Making a disableDelivery method call after delivery has already been disabled has no effect. |  | IF: EMSRIFT Func: EMSFT
| Use of the event mailbox service is ended when the lease granted by the event mailbox is cancelled or expires. |  | IF: EMSRIFT Func: EMSFT