aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations/Sorting
diff options
context:
space:
mode:
authorPatrick Barron <barronpm@gmail.com>2021-10-02 13:23:05 -0400
committerPatrick Barron <barronpm@gmail.com>2021-10-03 21:41:22 -0400
commit078200d8d4ba6d986cce8881b17d30b82e58b038 (patch)
tree84b9b5f478d08f6565a0a5b8bd33372f3886b47d /Emby.Server.Implementations/Sorting
parent1888e7ac216d4a06d3cf1675a820f034b3099740 (diff)
Fix warnings in Sorting
Diffstat (limited to 'Emby.Server.Implementations/Sorting')
-rw-r--r--Emby.Server.Implementations/Sorting/AiredEpisodeOrderComparer.cs12
-rw-r--r--Emby.Server.Implementations/Sorting/AlbumArtistComparer.cs12
-rw-r--r--Emby.Server.Implementations/Sorting/AlbumComparer.cs12
-rw-r--r--Emby.Server.Implementations/Sorting/CriticRatingComparer.cs12
-rw-r--r--Emby.Server.Implementations/Sorting/DateCreatedComparer.cs12
-rw-r--r--Emby.Server.Implementations/Sorting/DatePlayedComparer.cs12
-rw-r--r--Emby.Server.Implementations/Sorting/NameComparer.cs12
-rw-r--r--Emby.Server.Implementations/Sorting/PlayCountComparer.cs36
-rw-r--r--Emby.Server.Implementations/Sorting/PremiereDateComparer.cs12
-rw-r--r--Emby.Server.Implementations/Sorting/ProductionYearComparer.cs12
-rw-r--r--Emby.Server.Implementations/Sorting/RandomComparer.cs12
-rw-r--r--Emby.Server.Implementations/Sorting/RuntimeComparer.cs12
-rw-r--r--Emby.Server.Implementations/Sorting/SortNameComparer.cs12
-rw-r--r--Emby.Server.Implementations/Sorting/StudioComparer.cs12
14 files changed, 96 insertions, 96 deletions
diff --git a/Emby.Server.Implementations/Sorting/AiredEpisodeOrderComparer.cs b/Emby.Server.Implementations/Sorting/AiredEpisodeOrderComparer.cs
index 037eb170a..db8b68949 100644
--- a/Emby.Server.Implementations/Sorting/AiredEpisodeOrderComparer.cs
+++ b/Emby.Server.Implementations/Sorting/AiredEpisodeOrderComparer.cs
@@ -11,6 +11,12 @@ namespace Emby.Server.Implementations.Sorting
public class AiredEpisodeOrderComparer : IBaseItemComparer
{
/// <summary>
+ /// Gets the name.
+ /// </summary>
+ /// <value>The name.</value>
+ public string Name => ItemSortBy.AiredEpisodeOrder;
+
+ /// <summary>
/// Compares the specified x.
/// </summary>
/// <param name="x">The x.</param>
@@ -155,11 +161,5 @@ namespace Emby.Server.Implementations.Sorting
return comparisonResult;
}
-
- /// <summary>
- /// Gets the name.
- /// </summary>
- /// <value>The name.</value>
- public string Name => ItemSortBy.AiredEpisodeOrder;
}
}
diff --git a/Emby.Server.Implementations/Sorting/AlbumArtistComparer.cs b/Emby.Server.Implementations/Sorting/AlbumArtistComparer.cs
index 42e644970..bd1966623 100644
--- a/Emby.Server.Implementations/Sorting/AlbumArtistComparer.cs
+++ b/Emby.Server.Implementations/Sorting/AlbumArtistComparer.cs
@@ -13,6 +13,12 @@ namespace Emby.Server.Implementations.Sorting
public class AlbumArtistComparer : IBaseItemComparer
{
/// <summary>
+ /// Gets the name.
+ /// </summary>
+ /// <value>The name.</value>
+ public string Name => ItemSortBy.AlbumArtist;
+
+ /// <summary>
/// Compares the specified x.
/// </summary>
/// <param name="x">The x.</param>
@@ -34,11 +40,5 @@ namespace Emby.Server.Implementations.Sorting
return audio?.AlbumArtists.FirstOrDefault();
}
-
- /// <summary>
- /// Gets the name.
- /// </summary>
- /// <value>The name.</value>
- public string Name => ItemSortBy.AlbumArtist;
}
}
diff --git a/Emby.Server.Implementations/Sorting/AlbumComparer.cs b/Emby.Server.Implementations/Sorting/AlbumComparer.cs
index 1db3f5e9c..fe7dc84cb 100644
--- a/Emby.Server.Implementations/Sorting/AlbumComparer.cs
+++ b/Emby.Server.Implementations/Sorting/AlbumComparer.cs
@@ -12,6 +12,12 @@ namespace Emby.Server.Implementations.Sorting
public class AlbumComparer : IBaseItemComparer
{
/// <summary>
+ /// Gets the name.
+ /// </summary>
+ /// <value>The name.</value>
+ public string Name => ItemSortBy.Album;
+
+ /// <summary>
/// Compares the specified x.
/// </summary>
/// <param name="x">The x.</param>
@@ -33,11 +39,5 @@ namespace Emby.Server.Implementations.Sorting
return audio == null ? string.Empty : audio.Album;
}
-
- /// <summary>
- /// Gets the name.
- /// </summary>
- /// <value>The name.</value>
- public string Name => ItemSortBy.Album;
}
}
diff --git a/Emby.Server.Implementations/Sorting/CriticRatingComparer.cs b/Emby.Server.Implementations/Sorting/CriticRatingComparer.cs
index d20dedc2d..ba1835e4f 100644
--- a/Emby.Server.Implementations/Sorting/CriticRatingComparer.cs
+++ b/Emby.Server.Implementations/Sorting/CriticRatingComparer.cs
@@ -10,6 +10,12 @@ namespace Emby.Server.Implementations.Sorting
public class CriticRatingComparer : IBaseItemComparer
{
/// <summary>
+ /// Gets the name.
+ /// </summary>
+ /// <value>The name.</value>
+ public string Name => ItemSortBy.CriticRating;
+
+ /// <summary>
/// Compares the specified x.
/// </summary>
/// <param name="x">The x.</param>
@@ -24,11 +30,5 @@ namespace Emby.Server.Implementations.Sorting
{
return x?.CriticRating ?? 0;
}
-
- /// <summary>
- /// Gets the name.
- /// </summary>
- /// <value>The name.</value>
- public string Name => ItemSortBy.CriticRating;
}
}
diff --git a/Emby.Server.Implementations/Sorting/DateCreatedComparer.cs b/Emby.Server.Implementations/Sorting/DateCreatedComparer.cs
index d3f10f78c..8b460166c 100644
--- a/Emby.Server.Implementations/Sorting/DateCreatedComparer.cs
+++ b/Emby.Server.Implementations/Sorting/DateCreatedComparer.cs
@@ -11,6 +11,12 @@ namespace Emby.Server.Implementations.Sorting
public class DateCreatedComparer : IBaseItemComparer
{
/// <summary>
+ /// Gets the name.
+ /// </summary>
+ /// <value>The name.</value>
+ public string Name => ItemSortBy.DateCreated;
+
+ /// <summary>
/// Compares the specified x.
/// </summary>
/// <param name="x">The x.</param>
@@ -30,11 +36,5 @@ namespace Emby.Server.Implementations.Sorting
return DateTime.Compare(x.DateCreated, y.DateCreated);
}
-
- /// <summary>
- /// Gets the name.
- /// </summary>
- /// <value>The name.</value>
- public string Name => ItemSortBy.DateCreated;
}
}
diff --git a/Emby.Server.Implementations/Sorting/DatePlayedComparer.cs b/Emby.Server.Implementations/Sorting/DatePlayedComparer.cs
index 08a44319f..ec818253b 100644
--- a/Emby.Server.Implementations/Sorting/DatePlayedComparer.cs
+++ b/Emby.Server.Implementations/Sorting/DatePlayedComparer.cs
@@ -33,6 +33,12 @@ namespace Emby.Server.Implementations.Sorting
public IUserDataManager UserDataRepository { get; set; }
/// <summary>
+ /// Gets the name.
+ /// </summary>
+ /// <value>The name.</value>
+ public string Name => ItemSortBy.DatePlayed;
+
+ /// <summary>
/// Compares the specified x.
/// </summary>
/// <param name="x">The x.</param>
@@ -59,11 +65,5 @@ namespace Emby.Server.Implementations.Sorting
return DateTime.MinValue;
}
-
- /// <summary>
- /// Gets the name.
- /// </summary>
- /// <value>The name.</value>
- public string Name => ItemSortBy.DatePlayed;
}
}
diff --git a/Emby.Server.Implementations/Sorting/NameComparer.cs b/Emby.Server.Implementations/Sorting/NameComparer.cs
index 4de81a69e..8f87717f4 100644
--- a/Emby.Server.Implementations/Sorting/NameComparer.cs
+++ b/Emby.Server.Implementations/Sorting/NameComparer.cs
@@ -11,6 +11,12 @@ namespace Emby.Server.Implementations.Sorting
public class NameComparer : IBaseItemComparer
{
/// <summary>
+ /// Gets the name.
+ /// </summary>
+ /// <value>The name.</value>
+ public string Name => ItemSortBy.Name;
+
+ /// <summary>
/// Compares the specified x.
/// </summary>
/// <param name="x">The x.</param>
@@ -30,11 +36,5 @@ namespace Emby.Server.Implementations.Sorting
return string.Compare(x.Name, y.Name, StringComparison.CurrentCultureIgnoreCase);
}
-
- /// <summary>
- /// Gets the name.
- /// </summary>
- /// <value>The name.</value>
- public string Name => ItemSortBy.Name;
}
}
diff --git a/Emby.Server.Implementations/Sorting/PlayCountComparer.cs b/Emby.Server.Implementations/Sorting/PlayCountComparer.cs
index 04e4865cb..45c9044c5 100644
--- a/Emby.Server.Implementations/Sorting/PlayCountComparer.cs
+++ b/Emby.Server.Implementations/Sorting/PlayCountComparer.cs
@@ -20,6 +20,24 @@ namespace Emby.Server.Implementations.Sorting
public User User { get; set; }
/// <summary>
+ /// Gets the name.
+ /// </summary>
+ /// <value>The name.</value>
+ public string Name => ItemSortBy.PlayCount;
+
+ /// <summary>
+ /// Gets or sets the user data repository.
+ /// </summary>
+ /// <value>The user data repository.</value>
+ public IUserDataManager UserDataRepository { get; set; }
+
+ /// <summary>
+ /// Gets or sets the user manager.
+ /// </summary>
+ /// <value>The user manager.</value>
+ public IUserManager UserManager { get; set; }
+
+ /// <summary>
/// Compares the specified x.
/// </summary>
/// <param name="x">The x.</param>
@@ -41,23 +59,5 @@ namespace Emby.Server.Implementations.Sorting
return userdata == null ? 0 : userdata.PlayCount;
}
-
- /// <summary>
- /// Gets the name.
- /// </summary>
- /// <value>The name.</value>
- public string Name => ItemSortBy.PlayCount;
-
- /// <summary>
- /// Gets or sets the user data repository.
- /// </summary>
- /// <value>The user data repository.</value>
- public IUserDataManager UserDataRepository { get; set; }
-
- /// <summary>
- /// Gets or sets the user manager.
- /// </summary>
- /// <value>The user manager.</value>
- public IUserManager UserManager { get; set; }
}
}
diff --git a/Emby.Server.Implementations/Sorting/PremiereDateComparer.cs b/Emby.Server.Implementations/Sorting/PremiereDateComparer.cs
index c98f97bf1..b217556ef 100644
--- a/Emby.Server.Implementations/Sorting/PremiereDateComparer.cs
+++ b/Emby.Server.Implementations/Sorting/PremiereDateComparer.cs
@@ -11,6 +11,12 @@ namespace Emby.Server.Implementations.Sorting
public class PremiereDateComparer : IBaseItemComparer
{
/// <summary>
+ /// Gets the name.
+ /// </summary>
+ /// <value>The name.</value>
+ public string Name => ItemSortBy.PremiereDate;
+
+ /// <summary>
/// Compares the specified x.
/// </summary>
/// <param name="x">The x.</param>
@@ -52,11 +58,5 @@ namespace Emby.Server.Implementations.Sorting
return DateTime.MinValue;
}
-
- /// <summary>
- /// Gets the name.
- /// </summary>
- /// <value>The name.</value>
- public string Name => ItemSortBy.PremiereDate;
}
}
diff --git a/Emby.Server.Implementations/Sorting/ProductionYearComparer.cs b/Emby.Server.Implementations/Sorting/ProductionYearComparer.cs
index df9f9957d..d2022df7a 100644
--- a/Emby.Server.Implementations/Sorting/ProductionYearComparer.cs
+++ b/Emby.Server.Implementations/Sorting/ProductionYearComparer.cs
@@ -10,6 +10,12 @@ namespace Emby.Server.Implementations.Sorting
public class ProductionYearComparer : IBaseItemComparer
{
/// <summary>
+ /// Gets the name.
+ /// </summary>
+ /// <value>The name.</value>
+ public string Name => ItemSortBy.ProductionYear;
+
+ /// <summary>
/// Compares the specified x.
/// </summary>
/// <param name="x">The x.</param>
@@ -44,11 +50,5 @@ namespace Emby.Server.Implementations.Sorting
return 0;
}
-
- /// <summary>
- /// Gets the name.
- /// </summary>
- /// <value>The name.</value>
- public string Name => ItemSortBy.ProductionYear;
}
}
diff --git a/Emby.Server.Implementations/Sorting/RandomComparer.cs b/Emby.Server.Implementations/Sorting/RandomComparer.cs
index af3bc2750..bf0168222 100644
--- a/Emby.Server.Implementations/Sorting/RandomComparer.cs
+++ b/Emby.Server.Implementations/Sorting/RandomComparer.cs
@@ -11,6 +11,12 @@ namespace Emby.Server.Implementations.Sorting
public class RandomComparer : IBaseItemComparer
{
/// <summary>
+ /// Gets the name.
+ /// </summary>
+ /// <value>The name.</value>
+ public string Name => ItemSortBy.Random;
+
+ /// <summary>
/// Compares the specified x.
/// </summary>
/// <param name="x">The x.</param>
@@ -20,11 +26,5 @@ namespace Emby.Server.Implementations.Sorting
{
return Guid.NewGuid().CompareTo(Guid.NewGuid());
}
-
- /// <summary>
- /// Gets the name.
- /// </summary>
- /// <value>The name.</value>
- public string Name => ItemSortBy.Random;
}
}
diff --git a/Emby.Server.Implementations/Sorting/RuntimeComparer.cs b/Emby.Server.Implementations/Sorting/RuntimeComparer.cs
index 129315303..e32e5552e 100644
--- a/Emby.Server.Implementations/Sorting/RuntimeComparer.cs
+++ b/Emby.Server.Implementations/Sorting/RuntimeComparer.cs
@@ -13,6 +13,12 @@ namespace Emby.Server.Implementations.Sorting
public class RuntimeComparer : IBaseItemComparer
{
/// <summary>
+ /// Gets the name.
+ /// </summary>
+ /// <value>The name.</value>
+ public string Name => ItemSortBy.Runtime;
+
+ /// <summary>
/// Compares the specified x.
/// </summary>
/// <param name="x">The x.</param>
@@ -32,11 +38,5 @@ namespace Emby.Server.Implementations.Sorting
return (x.RunTimeTicks ?? 0).CompareTo(y.RunTimeTicks ?? 0);
}
-
- /// <summary>
- /// Gets the name.
- /// </summary>
- /// <value>The name.</value>
- public string Name => ItemSortBy.Runtime;
}
}
diff --git a/Emby.Server.Implementations/Sorting/SortNameComparer.cs b/Emby.Server.Implementations/Sorting/SortNameComparer.cs
index 8d30716d3..fb97a0349 100644
--- a/Emby.Server.Implementations/Sorting/SortNameComparer.cs
+++ b/Emby.Server.Implementations/Sorting/SortNameComparer.cs
@@ -13,6 +13,12 @@ namespace Emby.Server.Implementations.Sorting
public class SortNameComparer : IBaseItemComparer
{
/// <summary>
+ /// Gets the name.
+ /// </summary>
+ /// <value>The name.</value>
+ public string Name => ItemSortBy.SortName;
+
+ /// <summary>
/// Compares the specified x.
/// </summary>
/// <param name="x">The x.</param>
@@ -32,11 +38,5 @@ namespace Emby.Server.Implementations.Sorting
return string.Compare(x.SortName, y.SortName, StringComparison.CurrentCultureIgnoreCase);
}
-
- /// <summary>
- /// Gets the name.
- /// </summary>
- /// <value>The name.</value>
- public string Name => ItemSortBy.SortName;
}
}
diff --git a/Emby.Server.Implementations/Sorting/StudioComparer.cs b/Emby.Server.Implementations/Sorting/StudioComparer.cs
index 6826aee3b..4d89cfa8b 100644
--- a/Emby.Server.Implementations/Sorting/StudioComparer.cs
+++ b/Emby.Server.Implementations/Sorting/StudioComparer.cs
@@ -14,6 +14,12 @@ namespace Emby.Server.Implementations.Sorting
public class StudioComparer : IBaseItemComparer
{
/// <summary>
+ /// Gets the name.
+ /// </summary>
+ /// <value>The name.</value>
+ public string Name => ItemSortBy.Studio;
+
+ /// <summary>
/// Compares the specified x.
/// </summary>
/// <param name="x">The x.</param>
@@ -33,11 +39,5 @@ namespace Emby.Server.Implementations.Sorting
return AlphanumericComparator.CompareValues(x.Studios.FirstOrDefault(), y.Studios.FirstOrDefault());
}
-
- /// <summary>
- /// Gets the name.
- /// </summary>
- /// <value>The name.</value>
- public string Name => ItemSortBy.Studio;
}
}