A collection of appointments.
Definition
Namespace:Telerik.Web.UI
Assembly:Telerik.Web.UI.dll
Syntax:
public class AppointmentCollection : StateManagedCollection, IList, ICollection, IStateManager, IEnumerable<Appointment>, IEnumerable
Inheritance: objectStateManagedCollectionAppointmentCollection
Implements:
Inherited Members
Constructors
Creates an empty AppointmentCollection.
public AppointmentCollection()
Creates an AppointmentCollection and populates it with Appointment objects.
public AppointmentCollection(IEnumerable<Appointment> appointments)
The Appointment objects to add to the collection.
Properties
Gets or sets the Appointment at the specified index.
public Appointment this[int index] { get; set; }
The zero-based index of the Appointment to get or set.
Property Value:The appointment at the specified index.
Methods
Determines whether an element is in the AppointmentCollection.
public bool Contains(Appointment appointment)
The Appointment to locate in the AppointmentCollection.
Returns:true if item is found in the AppointmentCollection; otherwise, false.
This method performs a linear search; therefore, this method is an O(n) operation, where n is Count.
Copies the entire AppointmentCollection to a compatible one-dimensional Array, starting at the specified index of the target array.
public void CopyTo(Appointment[] array, int index)
The one-dimensional Array that is the destination of the Appointments copied from AppointmentCollection. The Array must have zero-based indexing.
indexintThe zero-based index in array at which copying begins.
Searches for an Appointment with the specified ID and returns a reference to it.
public Appointment FindByID(object id)
The Appointment ID to search for.
Returns:The Appointment with the specified ID, if found; otherwise, null.
Searches for all Appointment with the specified RecurrenceParentID and RecurrenceState.
public IList<Appointment> FindByRecurrenceParentID(object parentId, RecurrenceState state)
The RecurrenceParentID to search for.
stateRecurrenceStateThe RecurrenceState to search for.
Returns:A generic IList containing the Appointment with the specified RecurrenceParentID and RecurrenceState, if found.
Searches for all Appointment with the specified RecurrenceParentID and returns a generic IList containing them.
public IList<Appointment> FindByRecurrenceParentID(object parentId)
The RecurrenceParentID to search for.
Returns:A generic IList containing the Appointment with the specified RecurrenceParentID, if found.
This method determines equality by calling Equals(object).
Appointments with recurrence state Exception are linked to their parents using the RecurrenceParentID property.
Searches for all Appointment that are fully contained within the specified time range.
public IList<Appointment> GetAppointmentsEnclosingRange(DateTime rangeStart, DateTime rangeEnd)
The start of the time range.
rangeEndDateTimeThe end of the time range.
Returns:A generic IList containing the Appointment that are fully contained within the specified time range.
Searches for all Appointment that overlap with the specified time range and returns a generic IList containing them.
public IList<Appointment> GetAppointmentsInRange(DateTime rangeStart, DateTime rangeEnd)
The start of the time range.
rangeEndDateTimeThe end of the time range.
Returns:A generic IList containing the Appointment that overlap with the specified time range.
Searches for all Appointment that start in the specified time range and returns a generic IList containing them.
public IList<Appointment> GetAppointmentsStartingInRange(DateTime rangeStart, DateTime rangeEnd)
The start of the time range.
rangeEndDateTimeThe end of the time range.
Returns:A generic IList containing the Appointment that start in the specified time range.
Returns an enumerator for the entire AppointmentCollection.
public IEnumerator<Appointment> GetEnumerator()
An IEnumerator for the entire AppointmentCollection.
Implements:
Searches for the specified Appointment and returns the zero-based index of the first occurrence within the entire AppointmentCollection.
public int IndexOf(Appointment appointment)
The Appointment to locate in the AppointmentCollection.
Returns:The zero-based index of the first occurrence of value within the entire AppointmentCollection, if found; otherwise, -1.
Copies the elements of the AppointmentCollection to a new Appointment array.
public Appointment[] ToArray()
An Appointment array containing copies of the elements of the AppointmentCollection.