Skip to content

Commit

Permalink
Move ClockNotationRounding enum to root Humanizer namespace
Browse files Browse the repository at this point in the history
  • Loading branch information
strobelt committed Nov 11, 2021
1 parent 03a4409 commit fceb939
Show file tree
Hide file tree
Showing 8 changed files with 18 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
using System;
using Xunit;
using Humanizer.Localisation.TimeToClockNotation;
using Humanizer;

namespace Humanizer.Tests.Localisation.en
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
using System;
using Xunit;
using Humanizer.Localisation.TimeToClockNotation;
using Humanizer;

namespace Humanizer.Tests.Localisation.ptBR
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,11 @@ namespace Humanizer
{
public static string ApplyCase(this string input, Humanizer.LetterCasing casing) { }
}
public enum ClockNotationRounding
{
None = 0,
NearestFiveMinutes = 1,
}
public class static CollectionHumanizeExtensions
{
public static string Humanize<T>(this System.Collections.Generic.IEnumerable<T> collection) { }
Expand Down Expand Up @@ -1583,7 +1588,7 @@ namespace Humanizer
}
public class static TimeOnlyToClockNotationExtensions
{
public static string ToClockNotation(this System.TimeOnly input, Humanizer.Localisation.TimeToClockNotation.ClockNotationRounding roundToNearestFive = 0) { }
public static string ToClockNotation(this System.TimeOnly input, Humanizer.ClockNotationRounding roundToNearestFive = 0) { }
}
public class static TimeSpanHumanizeExtensions
{
Expand Down Expand Up @@ -1953,13 +1958,8 @@ namespace Humanizer.Localisation.Ordinalizers
}
namespace Humanizer.Localisation.TimeToClockNotation
{
public enum ClockNotationRounding
{
None = 0,
NearestFiveMinutes = 1,
}
public interface ITimeOnlyToClockNotationConverter
{
string Convert(System.TimeOnly time, Humanizer.Localisation.TimeToClockNotation.ClockNotationRounding roundToNearestFive);
string Convert(System.TimeOnly time, Humanizer.ClockNotationRounding roundToNearestFive);
}
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace Humanizer.Localisation.TimeToClockNotation
namespace Humanizer
{
public enum ClockNotationRounding
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

using System;

using Humanizer;

namespace Humanizer.Localisation.TimeToClockNotation
{
internal class BrazilianPortugueseTimeOnlyToClockNotationConverter : ITimeOnlyToClockNotationConverter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

using System;

using Humanizer;

namespace Humanizer.Localisation.TimeToClockNotation
{
internal class DefaultTimeOnlyToClockNotationConverter : ITimeOnlyToClockNotationConverter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

using System;

using Humanizer;

namespace Humanizer.Localisation.TimeToClockNotation
{
/// <summary>
Expand Down
2 changes: 2 additions & 0 deletions src/Humanizer/TimeOnlyToClockNotationExtensions.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
#if NET6_0_OR_GREATER

using System;

using Humanizer;
using Humanizer.Configuration;
using Humanizer.Localisation.TimeToClockNotation;

Expand Down

0 comments on commit fceb939

Please sign in to comment.