public interface AppointmentList extends OsidList
Like all OsidLists,
AppointmentList
provides a means for accessing Appointment
elements
sequentially either one at a time or many at a time. Examples:
while (al.hasNext()) { Appointment appointment = al.getNextAppointment(); }or
while (al.hasNext()) { Appointment[] appointments = al.getNextAppointments(al.available()); }
Modifier and Type | Method and Description |
---|---|
Appointment |
getNextAppointment()
Gets the next
Appointment in this list. |
Appointment[] |
getNextAppointments(long n)
Gets the next set of
Appointment elements in this list. |
Appointment getNextAppointment() throws OperationFailedException
Appointment
in this list. Appointment
in this list. The
hasNext()
method should be used to test that a next
Appointment
is available before calling this
method.IllegalStateException
- no more elements available in
this listOperationFailedException
- unable to complete requestmandatory
- This method must be implemented. Appointment[] getNextAppointments(long n) throws OperationFailedException
Appointment
elements in this list.
The specified amount must be less than or equal to the return from
available().
n
- the number of Appointment
elements requested
which must be less than or equal to available()
Appointment
elements.
The length of the array is less than or equal to the
number specified.IllegalStateException
- no more elements available in
this listOperationFailedException
- unable to complete requestmandatory
- This method must be implemented.