mirror of
https://github.com/sphildreth/roadie
synced 2024-11-23 04:33:16 +00:00
18 lines
420 B
C#
18 lines
420 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Text;
|
|
|
|
namespace Roadie.Library.Extensions
|
|
{
|
|
public static class TimeSpanExt
|
|
{
|
|
public static string ToDuration(this TimeSpan input)
|
|
{
|
|
if(input == null || input.TotalMilliseconds == 0)
|
|
{
|
|
return "--/--/--";
|
|
}
|
|
return input.ToString(@"ddd\.hh\:mm\:ss");
|
|
}
|
|
}
|
|
}
|