AK.F1.Timing.UI.Utility.Format.SectorTimeDelta C# (CSharp) Method

SectorTimeDelta() public static method

public static SectorTimeDelta ( System.TimeSpan value ) : string
value System.TimeSpan
return string
        public static string SectorTimeDelta(TimeSpan? value)
        {
            if(value == null)
            {
                return String.Empty;
            }

            string signSymbol;
            TimeSpan time = value.Value;

            if(time <= TimeSpan.Zero)
            {
                signSymbol = "-";
                time = TimeSpan.FromTicks(Math.Abs(time.Ticks));
            }
            else
            {
                signSymbol = "+";
            }

            return F("{0}{1}.{2:00}", signSymbol, time.Minutes * 60 + time.Seconds, time.Milliseconds / 10);
        }