diff options
| author | Jesse Plamondon-Willard <github@jplamondonw.com> | 2018-08-14 12:21:40 -0400 | 
|---|---|---|
| committer | Jesse Plamondon-Willard <github@jplamondonw.com> | 2018-08-14 12:21:40 -0400 | 
| commit | 4f28ea33bd7cc65485402c5e85259083e86b49e1 (patch) | |
| tree | 86c4d8f9272de9a715cfcbf4008f0c09f5a59a21 /src/StardewModdingAPI.Toolkit/Serialisation/Converters | |
| parent | 60b41195778af33fd609eab66d9ae3f1d1165e8f (diff) | |
| parent | 4dd4efc96fac6a7ab66c14edead10e4fa988040d (diff) | |
| download | SMAPI-4f28ea33bd7cc65485402c5e85259083e86b49e1.tar.gz SMAPI-4f28ea33bd7cc65485402c5e85259083e86b49e1.tar.bz2 SMAPI-4f28ea33bd7cc65485402c5e85259083e86b49e1.zip | |
Merge branch 'develop' into stable
Diffstat (limited to 'src/StardewModdingAPI.Toolkit/Serialisation/Converters')
| -rw-r--r-- | src/StardewModdingAPI.Toolkit/Serialisation/Converters/StringEnumConverter.cs | 22 | 
1 files changed, 0 insertions, 22 deletions
| diff --git a/src/StardewModdingAPI.Toolkit/Serialisation/Converters/StringEnumConverter.cs b/src/StardewModdingAPI.Toolkit/Serialisation/Converters/StringEnumConverter.cs deleted file mode 100644 index 13e6e3a1..00000000 --- a/src/StardewModdingAPI.Toolkit/Serialisation/Converters/StringEnumConverter.cs +++ /dev/null @@ -1,22 +0,0 @@ -using System; -using Newtonsoft.Json.Converters; - -namespace StardewModdingAPI.Toolkit.Serialisation.Converters -{ -    /// <summary>A variant of <see cref="StringEnumConverter"/> which only converts a specified enum.</summary> -    /// <typeparam name="T">The enum type.</typeparam> -    internal class StringEnumConverter<T> : StringEnumConverter -    { -        /********* -        ** Public methods -        *********/ -        /// <summary>Get whether this instance can convert the specified object type.</summary> -        /// <param name="type">The object type.</param> -        public override bool CanConvert(Type type) -        { -            return -                base.CanConvert(type) -                && (Nullable.GetUnderlyingType(type) ?? type) == typeof(T); -        } -    } -} | 
