C# Class csShared.Timeline.Rounding

Helper methods for time rounding
显示文件 Open project: TNOCS/csTouch

Public Properties

Property Type Description
MinuteSpan List

Public Methods

Method Description
RoundDateToMinuteInterval ( System.DateTime time, long minuteInterval, RoundingDirection direction ) : System.DateTime

Rounds a date value to a given minute interval

Private Methods

Method Description
GetInterval ( double th ) : long

Get nearby interval for a given timespan difference

Method Details

RoundDateToMinuteInterval() public static method

Rounds a date value to a given minute interval
public static RoundDateToMinuteInterval ( System.DateTime time, long minuteInterval, RoundingDirection direction ) : System.DateTime
time System.DateTime Original time value
minuteInterval long Number of minutes to round up or down to
direction RoundingDirection
return System.DateTime

Property Details

MinuteSpan public_oe static_oe property

public static List MinuteSpan
return List