/// <summary>
 /// Calculates the distance of time in words between two provided dates
 /// </summary>
 /// <param name="input">The input.</param>
 /// <param name="comparisonBase">The comparison base.</param>
 /// <param name="culture">The culture.</param>
 /// <returns>System.String.</returns>
 public string Humanize(DateTime input, DateTime comparisonBase, CultureInfo culture)
 {
     return(DateTimeHumanizeAlgorithms.DefaultHumanize(input, comparisonBase, culture));
 }
Esempio n. 2
0
 /// <summary>
 /// Returns localized &amp; humanized distance of time between two dates; given a specific precision.
 /// </summary>
 /// <param name="input">The input.</param>
 /// <param name="comparisonBase">The comparison base.</param>
 /// <param name="culture">The culture.</param>
 /// <returns>System.String.</returns>
 public string Humanize(DateTimeOffset input, DateTimeOffset comparisonBase, CultureInfo culture)
 {
     return(DateTimeHumanizeAlgorithms.PrecisionHumanize(input.UtcDateTime, comparisonBase.UtcDateTime, _precision, culture));
 }