New to Telerik UI for WPFStart a free 30-day trial

Provides class for appointment occurrence.

Definition

Namespace:Telerik.Windows.Controls.ScheduleView

Assembly:Telerik.Windows.Controls.ScheduleView.dll

Syntax:

C#
public class Occurrence : IOccurrence, IDateSpan, IEquatable<Occurrence>

Inheritance: objectOccurrence

Implements: IDateSpanIEquatable<Occurrence>IOccurrence

Properties

Gets the appointment for this occurrence.

C#
public IAppointment Appointment { get; }
Property Value:

The appointment for this occurrence.

Gets the end DateTime of the IDateSpan.

C#
public DateTime End { get; }
Property Value:

The end DateTime.

Implements: IDateSpan.End

Gets the master appointment for this occurrence. If this occurrence is an exception, this property is the master appointment for the exception; otherwise this property is the same as the Appointment property.

C#
public IAppointment Master { get; }
Property Value:

The master appointment.

Gets the date of the occurrence this exception is replacing.

C#
public DateTime OriginalStart { get; }

Gets the start DateTime of the IDateSpan.

C#
public DateTime Start { get; }
Property Value:

The start DateTime.

Implements: IDateSpan.Start

Gets the recurrence state.

C#
public RecurrenceState State { get; }
Property Value:

The state.

Methods

Creates a new instance of the Occurrence class with Exception state.

C#
public static Occurrence CreateException(IAppointment master, IAppointment exception, DateTime originalStart)
Parameters:masterIAppointment

The master.

exceptionIAppointment

The exception.

originalStartDateTime
Returns:

Occurrence

New occurrence with with Exception state.

Creates a new instance of the Occurrence class with Master state.

C#
public static Occurrence CreateMaster(IAppointment master)
Parameters:masterIAppointment

The master.

Returns:

Occurrence

Creates a new instance of the Occurrence class with Occurrence state.

C#
public static Occurrence CreateOccurrence(IAppointment master, DateTime start, DateTime end)
Parameters:masterIAppointment

The master.

startDateTime

The start.

endDateTime

The end.

Returns:

Occurrence

New occurrence with with Occurrence state.

Determines whether the specified Occurrence is equal to the current Occurrence.

C#
public override bool Equals(object obj)
Parameters:objobject

The Occurrence to compare with the current Occurrence.

Returns:

bool

True if the specified Occurrence is equal to the current Occurrence; otherwise, false.

Exceptions:

NullReferenceException

The obj parameter is null.

Overrides: object.Equals(object)

Indicates whether the current object is equal to another object of the same type.

C#
public bool Equals(Occurrence other)
Parameters:otherOccurrence

The object.

Returns:

bool

True if the current object is equal to the other parameter; otherwise, false.

Implements: IEquatable<Occurrence>.Equals(Occurrence)

Serves as a hash function for a particular type.

C#
public override int GetHashCode()
Returns:

int

A hash code for the current Occurrence.

Overrides: object.GetHashCode()

Returns a System.String that represents the current System.Object.

C#
public override string ToString()
Returns:

string

A System.String that represents the current System.Object.

Overrides: object.ToString()