org.sakaiproject.service.legacy.calendar
Class CalendarEventVector

java.lang.Object
  extended byjava.util.AbstractCollection
      extended byjava.util.AbstractList
          extended byjava.util.Vector
              extended byorg.sakaiproject.service.legacy.calendar.CalendarEventVector
All Implemented Interfaces:
Cloneable, Collection, List, RandomAccess, Serializable

public class CalendarEventVector
extends Vector

CalendarEventVector is a helper class for the Calendar service. It will read in a bunch of CalendarEvents from an iterator, place them into a vector, and provide time range controlled access to the events.

Use this to make larger, more user action aligned service requests, but still have fine grained time range access to the events returned.

Version:
$Revision: 632 $
Author:
University of Michigan, CHEF Software Development Team
See Also:
Serialized Form

Field Summary
 
Fields inherited from class java.util.Vector
capacityIncrement, elementCount, elementData
 
Fields inherited from class java.util.AbstractList
modCount
 
Constructor Summary
CalendarEventVector()
          Construct empty.
CalendarEventVector(Iterator events)
          Construct
 
Method Summary
 Iterator getEvents(TimeRange range)
          Return an iterator on events in the CalendarEventVector.
 
Methods inherited from class java.util.Vector
add, add, addAll, addAll, addElement, capacity, clear, clone, contains, containsAll, copyInto, elementAt, elements, ensureCapacity, equals, firstElement, get, hashCode, indexOf, indexOf, insertElementAt, isEmpty, lastElement, lastIndexOf, lastIndexOf, remove, remove, removeAll, removeAllElements, removeElement, removeElementAt, removeRange, retainAll, set, setElementAt, setSize, size, subList, toArray, toArray, toString, trimToSize
 
Methods inherited from class java.util.AbstractList
iterator, listIterator, listIterator
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.List
iterator, listIterator, listIterator
 

Constructor Detail

CalendarEventVector

public CalendarEventVector()
Construct empty.


CalendarEventVector

public CalendarEventVector(Iterator events)
Construct

Parameters:
events - An interator on CalendarEvents to load into the vector.
Method Detail

getEvents

public Iterator getEvents(TimeRange range)
Return an iterator on events in the CalendarEventVector. The order in which the events will be found in the iteration is by event start date.

Parameters:
range - A time range to limit the iterated events. May be null; all events will be returned.
Returns:
an iterator on CalendarEvent objects in the CalendarEventVector (may be empty).