Class PeriodSpan
ViewModel that represents a time period.
Inherited Members
Namespace: Telerik.Windows.Controls.TimeBar
Assembly: Telerik.Windows.Controls.DataVisualization.dll
Syntax
public class PeriodSpan : ViewModelBase, INotifyPropertyChanged, IDisposable, IComparable, IComparable<DateTime>, IComparable<PeriodSpan>, IPeriodSpan
Constructors
PeriodSpan(DateTime, TimeSpan)
Initializes a new instance of the Period
Declaration
public PeriodSpan(DateTime start, TimeSpan span)
Parameters
System. The start of the time interval. |
System. The System. |
Properties
EndDate
Gets the end of the time period.
Declaration
public DateTime EndDate { get; }
Property Value
System. The end of the time period. |
Implements
Interval
Gets the span of the time period.
Declaration
public TimeSpan Interval { get; }
Property Value
System. The span of the time period. |
Implements
Label
Gets or sets the label that represents the time period.
Declaration
public string Label { get; set; }
Property Value
System. The label that represents the time period. |
StartDate
Gets the start of the time period.
Declaration
public DateTime StartDate { get; }
Property Value
System. The start of the time period. |
Implements
Ticks
Gets the span of the time period in System.
Declaration
public long Ticks { get; }
Property Value
System. The span of the time period in System. |
Methods
CompareTo(DateTime)
Compares the current instance with another System.
Declaration
public int CompareTo(DateTime other)
Parameters
System. A System. |
Returns
System. A 32-bit signed integer that indicates the relative order of the objects being compared. The return value has the following meanings:
Value Meaning Less than zero This object is less than the |
CompareTo(Object)
Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object.
Declaration
public int CompareTo(object obj)
Parameters
System. An object to compare with this instance. |
Returns
System. A value that indicates the relative order of the objects being compared. The return value has these meanings:
Value Meaning Less than zero This instance precedes |
Exceptions
System.
|
CompareTo(PeriodSpan)
Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object.
Declaration
public int CompareTo(PeriodSpan other)
Parameters
Period A Period |
Returns
System. A 32-bit signed integer that indicates the relative order of the objects being compared. The return value has the following meanings:
Value Meaning Less than zero This object is less than the |
Equals(Object)
Determines whether the specified System.
Declaration
public override bool Equals(object obj)
Parameters
System. The System. |
Returns
System.
|
GetHashCode()
Returns a hash code for this instance.
Declaration
public override int GetHashCode()
Returns
System. A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table. |
Operators
Equality(PeriodSpan, PeriodSpan)
The equality operator (==) returns true
if its operands refer to the same Periodfalse
otherwise.
Declaration
public static bool operator ==(PeriodSpan periodSpan1, PeriodSpan periodSpan2)
Parameters
Period The first Period |
Period The second Period |
Returns
System.
|
GreaterThan(PeriodSpan, PeriodSpan)
The "greater than" relational operator (>) returns true
if the first operand is greater than the second, false
otherwise.
Declaration
public static bool operator>(PeriodSpan periodSpan1, PeriodSpan periodSpan2)
Parameters
Period The first Period |
Period The second Period |
Returns
System.
|
Inequality(PeriodSpan, PeriodSpan)
The inequality operator (!=) returns false
if its operands are equal, true
otherwise.
Declaration
public static bool operator !=(PeriodSpan periodSpan1, PeriodSpan periodSpan2)
Parameters
Period The first Period |
Period The second Period |
Returns
System.
|
LessThan(PeriodSpan, PeriodSpan)
The "less than" relational operator (<) returns true
if the first operand is less than the second, false
otherwise.
Declaration
public static bool operator <(PeriodSpan periodSpan1, PeriodSpan periodSpan2)
Parameters
Period The first Period |
Period The second Period |
Returns
System.
|