System::TimeSpan::CompareTo method

TimeSpan::CompareTo(const SharedPtr<Object>&) const method

Compares current and the specified objects.

int System::TimeSpan::CompareTo(const SharedPtr<Object> &obj) const
ParameterTypeDescription
objconst SharedPtr<Object>&The TimeSpan object to compare the current object with

ReturnValue

-1 if the current object represents the interval that is shorter than value; 0 if the current object represents the interval that is equal to value; 1 if the current object represents the interval that is longer than value

See Also

TimeSpan::CompareTo(TimeSpan) const method

Compares current and the specified objects.

int System::TimeSpan::CompareTo(TimeSpan value) const
ParameterTypeDescription
valueTimeSpanThe TimeSpan object to compare the current object with

ReturnValue

-1 if the current object represents the interval that is shorter than value; 0 if the current object represents the interval that is equal to value; 1 if the current object represents the interval that is longer than value

See Also