Table of Contents

Class TimeSpanOperator

Namespace
Ecng.Common
Assembly
Ecng.Common.dll

Implements arithmetic operations for TimeSpan values.

public class TimeSpanOperator : BaseOperator<TimeSpan>, IOperator<TimeSpan>, IComparer<TimeSpan>, IOperator, IComparer
Inheritance
TimeSpanOperator
Implements
Inherited Members
Extension Methods

Constructors

TimeSpanOperator()

public TimeSpanOperator()

Methods

Add(TimeSpan, TimeSpan)

Adds two TimeSpan values.

public override TimeSpan Add(TimeSpan first, TimeSpan second)

Parameters

first TimeSpan
second TimeSpan

Returns

TimeSpan

Compare(TimeSpan, TimeSpan)

Compares two TimeSpan values.

public override int Compare(TimeSpan first, TimeSpan second)

Parameters

first TimeSpan
second TimeSpan

Returns

int

Divide(TimeSpan, TimeSpan)

Divides two TimeSpan values by dividing their ticks.

public override TimeSpan Divide(TimeSpan first, TimeSpan second)

Parameters

first TimeSpan
second TimeSpan

Returns

TimeSpan

Multiply(TimeSpan, TimeSpan)

Multiplies two TimeSpan values by multiplying their ticks.

public override TimeSpan Multiply(TimeSpan first, TimeSpan second)

Parameters

first TimeSpan
second TimeSpan

Returns

TimeSpan

Subtract(TimeSpan, TimeSpan)

Subtracts the second TimeSpan from the first.

public override TimeSpan Subtract(TimeSpan first, TimeSpan second)

Parameters

first TimeSpan
second TimeSpan

Returns

TimeSpan