diff --git a/.vs/Stone_Red-C-Sharp-Utilities/v16/.suo b/.vs/Stone_Red-C-Sharp-Utilities/v16/.suo index 28c4b03..9ffbc3e 100644 Binary files a/.vs/Stone_Red-C-Sharp-Utilities/v16/.suo and b/.vs/Stone_Red-C-Sharp-Utilities/v16/.suo differ diff --git a/Stone_Red-C-Sharp-Utilities-Test/Program.cs b/Stone_Red-C-Sharp-Utilities-Test/Program.cs index d9378c4..52f66b3 100644 --- a/Stone_Red-C-Sharp-Utilities-Test/Program.cs +++ b/Stone_Red-C-Sharp-Utilities-Test/Program.cs @@ -1,10 +1,11 @@ -using Stone_Red_Utilities.BoolExtentions; -using Stone_Red_Utilities.ConsoleExtentions; -using Stone_Red_Utilities.FluentMath; +using Stone_Red_Utilities.Http; using Stone_Red_Utilities.Logging; +using Stone_Red_Utilities.Reflection; using System; -using System.Diagnostics; +using System.Net.Http; +using System.Text.Json.Serialization; +using System.Threading.Tasks; namespace Stone_Red_C_Sharp_Utilities_Test { @@ -46,38 +47,31 @@ namespace Stone_Red_C_Sharp_Utilities_Test } }; - private static void Main() + private static async Task Main() { - Trace.WriteLine("kek1"); - Debug.WriteLine("kek2"); - AppDomain.CurrentDomain.UnhandledException += CurrentDomain_UnhandledException; + HttpClient httpClient = new HttpClient(); + Quote quote = await httpClient.GetJsonObjectAsync("https://api.quotable.io/random"); + Console.WriteLine(quote.Id); + Console.WriteLine(quote.Content); + Console.WriteLine(quote.Author); - while (true) - { - ConsoleExt.Write("Enter the first number: ", ConsoleColor.Green); - bool success = int.TryParse(Console.ReadLine(), out int num1); + Quote q = quote.CopyProperties(); - ConsoleExt.Write("Enter the second number: ", ConsoleColor.Green); - success.OneWayFalse(int.TryParse(Console.ReadLine(), out int num2)); - - logger.LogIf(success, "Valid input!", LogSeverity.Debug); - - if (success) - { - Console.WriteLine($"{num1}/{num2} = {num1.Divide(num2)}"); - } - else - { - logger.Log("Invalid input!", "Calculator", LogSeverity.Warn); - } - } + Console.WriteLine(q.Id); + Console.WriteLine(q.Content); + Console.WriteLine(q.Author); } - private static void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs e) + private class Quote { - Exception exception = (Exception)e.ExceptionObject; + [JsonPropertyName("_id")] + public string Id { get; set; } - logger.Log(exception + (e.IsTerminating ? "\t Process terminating!" : ""), exception.Source, LogSeverity.Fatal); + [JsonPropertyName("content")] + public string Content { get; set; } + + [JsonPropertyName("author")] + public string Author { get; set; } } } } \ No newline at end of file diff --git a/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.deps.json b/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.deps.json index 1445eb0..77d9010 100644 --- a/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.deps.json +++ b/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.deps.json @@ -14,7 +14,18 @@ "Stone_Red-C-Sharp-Utilities-Test.dll": {} } }, + "System.Text.Json/5.0.2": { + "runtime": { + "lib/netcoreapp3.0/System.Text.Json.dll": { + "assemblyVersion": "5.0.0.0", + "fileVersion": "5.0.521.16609" + } + } + }, "Stone_Red-C-Sharp-Utilities/1.0.3.1": { + "dependencies": { + "System.Text.Json": "5.0.2" + }, "runtime": { "Stone_Red-C-Sharp-Utilities.dll": {} } @@ -27,6 +38,13 @@ "serviceable": false, "sha512": "" }, + "System.Text.Json/5.0.2": { + "type": "package", + "serviceable": true, + "sha512": "sha512-I47dVIGiV6SfAyppphxqupertT/5oZkYLDCX6vC3HpOI4ZLjyoKAreUoem2ie6G0RbRuFrlqz/PcTQjfb2DOfQ==", + "path": "system.text.json/5.0.2", + "hashPath": "system.text.json.5.0.2.nupkg.sha512" + }, "Stone_Red-C-Sharp-Utilities/1.0.3.1": { "type": "project", "serviceable": false, diff --git a/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.dll b/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.dll index dfff7b3..5d8648d 100644 Binary files a/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.dll and b/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.dll differ diff --git a/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.exe b/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.exe index 3fda31b..40bfceb 100644 Binary files a/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.exe and b/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.exe differ diff --git a/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.pdb b/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.pdb index 4904bee..c7990c7 100644 Binary files a/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.pdb and b/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.pdb differ diff --git a/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities.dll b/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities.dll index 486c934..e09343f 100644 Binary files a/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities.dll and b/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities.dll differ diff --git a/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities.pdb b/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities.pdb index c5fbffd..94ce8e7 100644 Binary files a/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities.pdb and b/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities.pdb differ diff --git a/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities.xml b/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities.xml index c9d38f6..b12a07a 100644 --- a/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities.xml +++ b/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/Stone_Red-C-Sharp-Utilities.xml @@ -6,7 +6,7 @@ - Extentions + Extensions @@ -44,7 +44,7 @@ - The default representaion of the table + The default representation of the table @@ -54,17 +54,17 @@ - The alternative representaion of the table + The alternative representation of the table - The list representaion of the table + The list representation of the table - and Extentions + and Extensions @@ -85,7 +85,7 @@ - Extentions + Extensions @@ -102,12 +102,18 @@ - + Suspends execution of the current method until the user presses a key - - + The key that has to be pressed + The message that will be displayed + + + + Suspends execution of the current method until the user presses a key + + The message that will be displayed @@ -143,8 +149,8 @@ Creates a new rectangle instance - - + The length of the rectangle + The width of the rectangle @@ -204,7 +210,7 @@ - Multiplys the two nums + Multiples the two nums @@ -306,7 +312,7 @@ - Multiplys the two nums + Multiples the two nums @@ -471,7 +477,7 @@ - Multiplys the two nums + Multiples the two nums @@ -552,7 +558,7 @@ - Multiplys the two nums + Multiples the two nums @@ -633,7 +639,7 @@ - Multiplys the two nums + Multiples the two nums @@ -714,7 +720,7 @@ - Multiplys the two nums + Multiples the two nums @@ -863,7 +869,7 @@ - The onsole color of the log message. + The console color of the log message. @@ -878,7 +884,7 @@ - Foramt configuration. + Format configuration. @@ -1047,7 +1053,7 @@ - Extentions + Extensions @@ -1100,7 +1106,7 @@ - Extentions + Extensions @@ -1169,7 +1175,7 @@ - Revoves all whitespaces from the specified + Removes all white spaces from the specified diff --git a/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/ref/Stone_Red-C-Sharp-Utilities-Test.dll b/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/ref/Stone_Red-C-Sharp-Utilities-Test.dll index 5c1bb81..3a6db7d 100644 Binary files a/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/ref/Stone_Red-C-Sharp-Utilities-Test.dll and b/Stone_Red-C-Sharp-Utilities-Test/bin/Release/net5.0/ref/Stone_Red-C-Sharp-Utilities-Test.dll differ diff --git a/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.assets.cache b/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.assets.cache index edc1958..411750a 100644 Binary files a/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.assets.cache and b/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.assets.cache differ diff --git a/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.csproj.CoreCompileInputs.cache b/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.csproj.CoreCompileInputs.cache index 32f8f69..2342814 100644 --- a/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.csproj.CoreCompileInputs.cache +++ b/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.csproj.CoreCompileInputs.cache @@ -1 +1 @@ -5375b33f90ea389df924475d2d3675a20dffae64 +29b9737293ccbe2493bdaac0f5685c008bec1abb diff --git a/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.csproj.FileListAbsolute.txt b/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.csproj.FileListAbsolute.txt index 7426191..25ab566 100644 --- a/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.csproj.FileListAbsolute.txt +++ b/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.csproj.FileListAbsolute.txt @@ -38,3 +38,4 @@ C:\Users\David\Programmieren\Stone_Red-C-Sharp-Utilities\Stone_Red-C-Sharp-Utili C:\Users\David\Programmieren\Stone_Red-C-Sharp-Utilities\Stone_Red-C-Sharp-Utilities-Test\obj\Release\net5.0\ref\Stone_Red-C-Sharp-Utilities-Test.dll C:\Users\David\Programmieren\Stone_Red-C-Sharp-Utilities\Stone_Red-C-Sharp-Utilities-Test\obj\Release\net5.0\Stone_Red-C-Sharp-Utilities-Test.pdb C:\Users\David\Programmieren\Stone_Red-C-Sharp-Utilities\Stone_Red-C-Sharp-Utilities-Test\obj\Release\net5.0\Stone_Red-C-Sharp-Utilities-Test.genruntimeconfig.cache +C:\Users\David\Programmieren\Stone_Red-C-Sharp-Utilities\Stone_Red-C-Sharp-Utilities-Test\bin\Release\net5.0\System.Text.Json.dll diff --git a/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.dll b/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.dll index dfff7b3..5d8648d 100644 Binary files a/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.dll and b/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.dll differ diff --git a/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.pdb b/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.pdb index 4904bee..c7990c7 100644 Binary files a/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.pdb and b/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/Stone_Red-C-Sharp-Utilities-Test.pdb differ diff --git a/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/apphost.exe b/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/apphost.exe index 3fda31b..40bfceb 100644 Binary files a/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/apphost.exe and b/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/apphost.exe differ diff --git a/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/ref/Stone_Red-C-Sharp-Utilities-Test.dll b/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/ref/Stone_Red-C-Sharp-Utilities-Test.dll index 5c1bb81..3a6db7d 100644 Binary files a/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/ref/Stone_Red-C-Sharp-Utilities-Test.dll and b/Stone_Red-C-Sharp-Utilities-Test/obj/Release/net5.0/ref/Stone_Red-C-Sharp-Utilities-Test.dll differ diff --git a/Stone_Red-C-Sharp-Utilities-Test/obj/Stone_Red-C-Sharp-Utilities-Test.csproj.nuget.dgspec.json b/Stone_Red-C-Sharp-Utilities-Test/obj/Stone_Red-C-Sharp-Utilities-Test.csproj.nuget.dgspec.json index 4be8540..493ae0d 100644 --- a/Stone_Red-C-Sharp-Utilities-Test/obj/Stone_Red-C-Sharp-Utilities-Test.csproj.nuget.dgspec.json +++ b/Stone_Red-C-Sharp-Utilities-Test/obj/Stone_Red-C-Sharp-Utilities-Test.csproj.nuget.dgspec.json @@ -63,7 +63,7 @@ "privateAssets": "all" } }, - "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\5.0.401\\RuntimeIdentifierGraph.json" + "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\5.0.402\\RuntimeIdentifierGraph.json" } } }, @@ -108,6 +108,10 @@ "netstandard2.1": { "targetAlias": "netstandard2.1", "dependencies": { + "System.Text.Json": { + "target": "Package", + "version": "[5.0.2, )" + }, "Vsxmd": { "include": "Runtime, Build, Native, ContentFiles, Analyzers, BuildTransitive", "suppressParent": "All", @@ -130,7 +134,7 @@ "privateAssets": "all" } }, - "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\5.0.401\\RuntimeIdentifierGraph.json" + "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\5.0.402\\RuntimeIdentifierGraph.json" } } } diff --git a/Stone_Red-C-Sharp-Utilities-Test/obj/project.assets.json b/Stone_Red-C-Sharp-Utilities-Test/obj/project.assets.json index 33993ab..a2e04fb 100644 --- a/Stone_Red-C-Sharp-Utilities-Test/obj/project.assets.json +++ b/Stone_Red-C-Sharp-Utilities-Test/obj/project.assets.json @@ -2,9 +2,21 @@ "version": 3, "targets": { "net5.0": { + "System.Text.Json/5.0.2": { + "type": "package", + "compile": { + "lib/netcoreapp3.0/System.Text.Json.dll": {} + }, + "runtime": { + "lib/netcoreapp3.0/System.Text.Json.dll": {} + } + }, "Stone_Red-C-Sharp-Utilities/1.0.3.1": { "type": "project", "framework": ".NETStandard,Version=v2.1", + "dependencies": { + "System.Text.Json": "5.0.2" + }, "compile": { "bin/placeholder/Stone_Red-C-Sharp-Utilities.dll": {} }, @@ -15,6 +27,28 @@ } }, "libraries": { + "System.Text.Json/5.0.2": { + "sha512": "I47dVIGiV6SfAyppphxqupertT/5oZkYLDCX6vC3HpOI4ZLjyoKAreUoem2ie6G0RbRuFrlqz/PcTQjfb2DOfQ==", + "type": "package", + "path": "system.text.json/5.0.2", + "files": [ + ".nupkg.metadata", + ".signature.p7s", + "Icon.png", + "LICENSE.TXT", + "THIRD-PARTY-NOTICES.TXT", + "lib/net461/System.Text.Json.dll", + "lib/net461/System.Text.Json.xml", + "lib/netcoreapp3.0/System.Text.Json.dll", + "lib/netcoreapp3.0/System.Text.Json.xml", + "lib/netstandard2.0/System.Text.Json.dll", + "lib/netstandard2.0/System.Text.Json.xml", + "system.text.json.5.0.2.nupkg.sha512", + "system.text.json.nuspec", + "useSharedDesignerContext.txt", + "version.txt" + ] + }, "Stone_Red-C-Sharp-Utilities/1.0.3.1": { "type": "project", "path": "../Stone_Red-C-Sharp-Utilities/Stone_Red-C-Sharp-Utilities.csproj", @@ -89,7 +123,7 @@ "privateAssets": "all" } }, - "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\5.0.401\\RuntimeIdentifierGraph.json" + "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\5.0.402\\RuntimeIdentifierGraph.json" } } } diff --git a/Stone_Red-C-Sharp-Utilities-Test/obj/project.nuget.cache b/Stone_Red-C-Sharp-Utilities-Test/obj/project.nuget.cache index 794db4d..00f9dc1 100644 --- a/Stone_Red-C-Sharp-Utilities-Test/obj/project.nuget.cache +++ b/Stone_Red-C-Sharp-Utilities-Test/obj/project.nuget.cache @@ -1,8 +1,11 @@ { "version": 2, - "dgSpecHash": "i9sxl0DK4prGdivFoHN0urjiTdeJN7pdMVng46dayLfJokZ9N5lHYpWasE93pEfNg8KMgQDtDsbVnvjJQeZa6g==", + "dgSpecHash": "Vx9qsK3Yk9tZYtINnXECOYONnvtrMwwty0hl6iIWBvlkyK4NCks9Q8TNs/UBn8LVsiXed1iLDXPWnVB0LDNx5g==", "success": true, "projectFilePath": "C:\\Users\\David\\Programmieren\\Stone_Red-C-Sharp-Utilities\\Stone_Red-C-Sharp-Utilities-Test\\Stone_Red-C-Sharp-Utilities-Test.csproj", - "expectedPackageFiles": [], + "expectedPackageFiles": [ + "C:\\Users\\David\\.nuget\\packages\\system.text.json\\5.0.2\\system.text.json.5.0.2.nupkg.sha512", + "C:\\Users\\David\\.nuget\\packages\\stone_red-c-sharp-utilities\\1.0.3.1\\stone_red-c-sharp-utilities.1.0.3.1.nupkg.sha512" + ], "logs": [] } \ No newline at end of file diff --git a/Stone_Red-C-Sharp-Utilities/BoolExtentions.cs b/Stone_Red-C-Sharp-Utilities/BoolExtentions.cs index 311f6c8..fbccf40 100644 --- a/Stone_Red-C-Sharp-Utilities/BoolExtentions.cs +++ b/Stone_Red-C-Sharp-Utilities/BoolExtentions.cs @@ -1,7 +1,7 @@ namespace Stone_Red_Utilities.BoolExtentions { /// - /// Extentions + /// Extensions /// public static class BoolExt { diff --git a/Stone_Red-C-Sharp-Utilities/CollectionExtentions.cs b/Stone_Red-C-Sharp-Utilities/CollectionExtentions.cs index b803bca..89a8d82 100644 --- a/Stone_Red-C-Sharp-Utilities/CollectionExtentions.cs +++ b/Stone_Red-C-Sharp-Utilities/CollectionExtentions.cs @@ -11,7 +11,7 @@ namespace Stone_Red_Utilities.CollectionExtentions public enum TableStyle { /// - /// The default representaion of the table + /// The default representation of the table /// Default, @@ -21,18 +21,18 @@ namespace Stone_Red_Utilities.CollectionExtentions Minimum, /// - /// The alternative representaion of the table + /// The alternative representation of the table /// Alternative, /// - /// The list representaion of the table + /// The list representation of the table /// List } /// - /// and Extentions + /// and Extensions /// public static class CollectionExt { diff --git a/Stone_Red-C-Sharp-Utilities/ConsoleExtentions.cs b/Stone_Red-C-Sharp-Utilities/ConsoleExtentions.cs index 783395e..bc87038 100644 --- a/Stone_Red-C-Sharp-Utilities/ConsoleExtentions.cs +++ b/Stone_Red-C-Sharp-Utilities/ConsoleExtentions.cs @@ -1,9 +1,10 @@ using System; +using System.ComponentModel; namespace Stone_Red_Utilities.ConsoleExtentions { /// - /// Extentions + /// Extensions /// public static class ConsoleExt { @@ -39,37 +40,91 @@ namespace Stone_Red_Utilities.ConsoleExtentions } } + public static T ReadLine() + { + string attemptedValue = Console.ReadLine(); + Type type = typeof(T); + TypeConverter converter = TypeDescriptor.GetConverter(type); + if (converter != null && converter.IsValid(attemptedValue)) + { + return (T)converter.ConvertFromString(attemptedValue); + } + else + { + return default; + } + } + + public static bool TryReadLine(out T input) + { + string attemptedValue = Console.ReadLine(); + Type type = typeof(T); + TypeConverter converter = TypeDescriptor.GetConverter(type); + if (converter != null && converter.IsValid(attemptedValue)) + { + input = (T)converter.ConvertFromString(attemptedValue); + return true; + } + else + { + input = default; + return false; + } + } + + public static T ReadKey() + { + string attemptedValue = Console.ReadKey().KeyChar.ToString(); + Type type = typeof(T); + TypeConverter converter = TypeDescriptor.GetConverter(type); + if (converter != null && converter.IsValid(attemptedValue)) + { + return (T)converter.ConvertFromString(attemptedValue); + } + else + { + return default; + } + } + + public static bool TryReadKey(out T input) + { + string attemptedValue = Console.ReadKey().KeyChar.ToString(); + Type type = typeof(T); + TypeConverter converter = TypeDescriptor.GetConverter(type); + if (converter != null && converter.IsValid(attemptedValue)) + { + input = (T)converter.ConvertFromString(attemptedValue); + return true; + } + else + { + input = default; + return false; + } + } + /// /// Suspends execution of the current method until the user presses a key /// - /// - /// - public static void Pause(bool enterKeyOnly = false, string customMessage = null) + /// The key that has to be pressed + /// The message that will be displayed + public static void Pause(ConsoleKey key, string message = null) { - if (customMessage is null) + Console.WriteLine(message ?? $"Press {key} to continue..."); + while (Console.ReadKey(true).Key != key) { - if (enterKeyOnly) - { - Console.WriteLine("Press ENTER to continue."); - } - else - { - Console.WriteLine("Press any key to continue."); - } - } - else - { - Console.WriteLine(customMessage); } + } - if (enterKeyOnly) - { - Console.ReadLine(); - } - else - { - Console.ReadKey(); - } + /// + /// Suspends execution of the current method until the user presses a key + /// + /// The message that will be displayed + public static void Pause(string message = "Press any key to continue...") + { + Console.WriteLine(message); + Console.ReadKey(true); } } } \ No newline at end of file diff --git a/Stone_Red-C-Sharp-Utilities/FluentMath/Shapes/Rectangle.cs b/Stone_Red-C-Sharp-Utilities/FluentMath/Shapes/Rectangle.cs index b5cbbc0..4156eb7 100644 --- a/Stone_Red-C-Sharp-Utilities/FluentMath/Shapes/Rectangle.cs +++ b/Stone_Red-C-Sharp-Utilities/FluentMath/Shapes/Rectangle.cs @@ -20,7 +20,7 @@ namespace Stone_Red_Utilities.FluentMath.Shapes /// /// The diagonal of the /// - public double Diagonal => System.Math.Sqrt(Math.Pow(Length, 2) + Math.Pow(Width, 2)); + public double Diagonal => Math.Sqrt(Math.Pow(Length, 2) + Math.Pow(Width, 2)); /// /// The area of the @@ -35,8 +35,8 @@ namespace Stone_Red_Utilities.FluentMath.Shapes /// /// Creates a new rectangle instance /// - /// - /// + /// The length of the rectangle + /// The width of the rectangle public Rectangle(double length, double width) { Length = length; diff --git a/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/DecimalFluent.cs b/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/DecimalFluent.cs index 3bb10a0..87db0a7 100644 --- a/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/DecimalFluent.cs +++ b/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/DecimalFluent.cs @@ -80,7 +80,7 @@ namespace Stone_Red_Utilities.FluentMath } /// - /// Multiplys the two nums + /// Multiples the two nums /// /// /// diff --git a/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/DoubleFluent.cs b/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/DoubleFluent.cs index 1df01cc..dd6e6d7 100644 --- a/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/DoubleFluent.cs +++ b/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/DoubleFluent.cs @@ -80,7 +80,7 @@ namespace Stone_Red_Utilities.FluentMath } /// - /// Multiplys the two nums + /// Multiples the two nums /// /// /// diff --git a/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/Int16Fluent.cs b/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/Int16Fluent.cs index b049c3a..8fe9a8d 100644 --- a/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/Int16Fluent.cs +++ b/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/Int16Fluent.cs @@ -80,7 +80,7 @@ namespace Stone_Red_Utilities.FluentMath } /// - /// Multiplys the two nums + /// Multiples the two nums /// /// /// diff --git a/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/Int32Fluent.cs b/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/Int32Fluent.cs index 5c5c2c0..b94ac06 100644 --- a/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/Int32Fluent.cs +++ b/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/Int32Fluent.cs @@ -80,7 +80,7 @@ namespace Stone_Red_Utilities.FluentMath } /// - /// Multiplys the two nums + /// Multiples the two nums /// /// /// diff --git a/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/Int64Fluent.cs b/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/Int64Fluent.cs index 49f4878..bb92caf 100644 --- a/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/Int64Fluent.cs +++ b/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/Int64Fluent.cs @@ -80,7 +80,7 @@ namespace Stone_Red_Utilities.FluentMath } /// - /// Multiplys the two nums + /// Multiples the two nums /// /// /// diff --git a/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/SingleFluent.cs b/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/SingleFluent.cs index f4f0f1b..f2d2a80 100644 --- a/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/SingleFluent.cs +++ b/Stone_Red-C-Sharp-Utilities/FluentMath/TypeExtentions/SingleFluent.cs @@ -80,7 +80,7 @@ namespace Stone_Red_Utilities.FluentMath } /// - /// Multiplys the two nums + /// Multiples the two nums /// /// /// diff --git a/Stone_Red-C-Sharp-Utilities/HttpClient.cs b/Stone_Red-C-Sharp-Utilities/HttpClient.cs new file mode 100644 index 0000000..860d879 --- /dev/null +++ b/Stone_Red-C-Sharp-Utilities/HttpClient.cs @@ -0,0 +1,20 @@ +using System; +using System.Net.Http; +using System.Text.Json; +using System.Threading.Tasks; + +namespace Stone_Red_Utilities.Http +{ + public static class HttpClientExtentions + { + public static async Task GetJsonObjectAsync(this HttpClient httpClient, string requestUri) + { + return JsonSerializer.Deserialize(await httpClient.GetStringAsync(requestUri)); + } + + public static async Task GetJsonObjectAsync(this HttpClient httpClient, Uri requestUri) + { + return JsonSerializer.Deserialize(await httpClient.GetStringAsync(requestUri)); + } + } +} \ No newline at end of file diff --git a/Stone_Red-C-Sharp-Utilities/Logging/LogConfig.cs b/Stone_Red-C-Sharp-Utilities/Logging/LogConfig.cs index 2de7493..18f5dde 100644 --- a/Stone_Red-C-Sharp-Utilities/Logging/LogConfig.cs +++ b/Stone_Red-C-Sharp-Utilities/Logging/LogConfig.cs @@ -44,7 +44,7 @@ namespace Stone_Red_Utilities.Logging public class OutputConfig { /// - /// The onsole color of the log message. + /// The console color of the log message. /// public ConsoleColor Color { get; set; } = ConsoleColor.White; @@ -60,7 +60,7 @@ namespace Stone_Red_Utilities.Logging } /// - /// Foramt configuration. + /// Format configuration. /// public class FormatConfig { diff --git a/Stone_Red-C-Sharp-Utilities/RandomExtentions.cs b/Stone_Red-C-Sharp-Utilities/RandomExtentions.cs index 472a10a..7f7352e 100644 --- a/Stone_Red-C-Sharp-Utilities/RandomExtentions.cs +++ b/Stone_Red-C-Sharp-Utilities/RandomExtentions.cs @@ -5,7 +5,7 @@ using System.Linq; namespace Stone_Red_Utilities.RandomExtentions { /// - /// Extentions + /// Extensions /// public static class RandomExt { diff --git a/Stone_Red-C-Sharp-Utilities/Stone_Red-C-Sharp-Utilities.csproj b/Stone_Red-C-Sharp-Utilities/Stone_Red-C-Sharp-Utilities.csproj index f3bbf80..a7eee47 100644 --- a/Stone_Red-C-Sharp-Utilities/Stone_Red-C-Sharp-Utilities.csproj +++ b/Stone_Red-C-Sharp-Utilities/Stone_Red-C-Sharp-Utilities.csproj @@ -33,6 +33,7 @@ + all runtime; build; native; contentfiles; analyzers; buildtransitive diff --git a/Stone_Red-C-Sharp-Utilities/Stone_Red-C-Sharp-Utilities.md b/Stone_Red-C-Sharp-Utilities/Stone_Red-C-Sharp-Utilities.md index a760296..9cd6ac0 100644 --- a/Stone_Red-C-Sharp-Utilities/Stone_Red-C-Sharp-Utilities.md +++ b/Stone_Red-C-Sharp-Utilities/Stone_Red-C-Sharp-Utilities.md @@ -492,7 +492,7 @@ This method has no parameters. ##### Summary -Multiplys the two nums +Multiples the two nums ##### Returns @@ -935,7 +935,7 @@ This method has no parameters. ##### Summary -Multiplys the two nums +Multiples the two nums ##### Returns @@ -1289,7 +1289,7 @@ Divides the two nums ##### Summary -Multiplys the two nums +Multiples the two nums ##### Returns @@ -1490,7 +1490,7 @@ Divides the two nums ##### Summary -Multiplys the two nums +Multiples the two nums ##### Returns @@ -1691,7 +1691,7 @@ Divides the two nums ##### Summary -Multiplys the two nums +Multiples the two nums ##### Returns @@ -2608,7 +2608,7 @@ This method has no parameters. ##### Summary -Multiplys the two nums +Multiples the two nums ##### Returns diff --git a/Stone_Red-C-Sharp-Utilities/Stone_Red-C-Sharp-Utilities.xml b/Stone_Red-C-Sharp-Utilities/Stone_Red-C-Sharp-Utilities.xml index c9d38f6..aebc956 100644 --- a/Stone_Red-C-Sharp-Utilities/Stone_Red-C-Sharp-Utilities.xml +++ b/Stone_Red-C-Sharp-Utilities/Stone_Red-C-Sharp-Utilities.xml @@ -6,7 +6,7 @@ - Extentions + Extensions @@ -44,7 +44,7 @@ - The default representaion of the table + The default representation of the table @@ -54,17 +54,17 @@ - The alternative representaion of the table + The alternative representation of the table - The list representaion of the table + The list representation of the table - and Extentions + and Extensions @@ -85,7 +85,7 @@ - Extentions + Extensions @@ -204,7 +204,7 @@ - Multiplys the two nums + Multiples the two nums @@ -306,7 +306,7 @@ - Multiplys the two nums + Multiples the two nums @@ -471,7 +471,7 @@ - Multiplys the two nums + Multiples the two nums @@ -552,7 +552,7 @@ - Multiplys the two nums + Multiples the two nums @@ -633,7 +633,7 @@ - Multiplys the two nums + Multiples the two nums @@ -714,7 +714,7 @@ - Multiplys the two nums + Multiples the two nums @@ -863,7 +863,7 @@ - The onsole color of the log message. + The console color of the log message. @@ -878,7 +878,7 @@ - Foramt configuration. + Format configuration. @@ -1047,7 +1047,7 @@ - Extentions + Extensions @@ -1100,7 +1100,7 @@ - Extentions + Extensions @@ -1169,7 +1169,7 @@ - Revoves all whitespaces from the specified + Removes all white spaces from the specified diff --git a/Stone_Red-C-Sharp-Utilities/StringExtentions.cs b/Stone_Red-C-Sharp-Utilities/StringExtentions.cs index 3ee383d..06d6426 100644 --- a/Stone_Red-C-Sharp-Utilities/StringExtentions.cs +++ b/Stone_Red-C-Sharp-Utilities/StringExtentions.cs @@ -6,7 +6,7 @@ using System.Text; namespace Stone_Red_Utilities.StringExtentions { /// - /// Extentions + /// Extensions /// public static class StringExt { @@ -140,7 +140,7 @@ namespace Stone_Red_Utilities.StringExtentions { if (str.Length > length && length > 0) { - if (ellipsis) + if (ellipsis && length > 3) { return $"{str.Substring(0, length - 3)}..."; } @@ -173,7 +173,7 @@ namespace Stone_Red_Utilities.StringExtentions } /// - /// Revoves all whitespaces from the specified + /// Removes all white spaces from the specified /// /// /// diff --git a/Stone_Red-C-Sharp-Utilities/bin/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.deps.json b/Stone_Red-C-Sharp-Utilities/bin/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.deps.json index 8c34003..4d8d091 100644 --- a/Stone_Red-C-Sharp-Utilities/bin/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.deps.json +++ b/Stone_Red-C-Sharp-Utilities/bin/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.deps.json @@ -9,12 +9,94 @@ ".NETStandard,Version=v2.1/": { "Stone_Red-C-Sharp-Utilities/1.0.3.1": { "dependencies": { + "System.Text.Json": "5.0.2", "Vsxmd": "1.4.5" }, "runtime": { "Stone_Red-C-Sharp-Utilities.dll": {} } }, + "Microsoft.Bcl.AsyncInterfaces/5.0.0": { + "runtime": { + "lib/netstandard2.1/Microsoft.Bcl.AsyncInterfaces.dll": { + "assemblyVersion": "5.0.0.0", + "fileVersion": "5.0.20.51904" + } + } + }, + "System.Buffers/4.5.1": { + "runtime": { + "lib/netstandard2.0/System.Buffers.dll": { + "assemblyVersion": "4.0.3.0", + "fileVersion": "4.6.28619.1" + } + } + }, + "System.Memory/4.5.4": { + "dependencies": { + "System.Buffers": "4.5.1", + "System.Numerics.Vectors": "4.5.0", + "System.Runtime.CompilerServices.Unsafe": "5.0.0" + }, + "runtime": { + "lib/netstandard2.0/System.Memory.dll": { + "assemblyVersion": "4.0.1.1", + "fileVersion": "4.6.28619.1" + } + } + }, + "System.Numerics.Vectors/4.5.0": { + "runtime": { + "lib/netstandard2.0/System.Numerics.Vectors.dll": { + "assemblyVersion": "4.1.4.0", + "fileVersion": "4.6.26515.6" + } + } + }, + "System.Runtime.CompilerServices.Unsafe/5.0.0": { + "runtime": { + "lib/netstandard2.0/System.Runtime.CompilerServices.Unsafe.dll": { + "assemblyVersion": "5.0.0.0", + "fileVersion": "5.0.20.51904" + } + } + }, + "System.Text.Encodings.Web/5.0.1": { + "runtime": { + "lib/netstandard2.1/System.Text.Encodings.Web.dll": { + "assemblyVersion": "5.0.0.1", + "fileVersion": "5.0.421.11614" + } + } + }, + "System.Text.Json/5.0.2": { + "dependencies": { + "Microsoft.Bcl.AsyncInterfaces": "5.0.0", + "System.Buffers": "4.5.1", + "System.Memory": "4.5.4", + "System.Numerics.Vectors": "4.5.0", + "System.Runtime.CompilerServices.Unsafe": "5.0.0", + "System.Text.Encodings.Web": "5.0.1", + "System.Threading.Tasks.Extensions": "4.5.4" + }, + "runtime": { + "lib/netstandard2.0/System.Text.Json.dll": { + "assemblyVersion": "5.0.0.0", + "fileVersion": "5.0.521.16609" + } + } + }, + "System.Threading.Tasks.Extensions/4.5.4": { + "dependencies": { + "System.Runtime.CompilerServices.Unsafe": "5.0.0" + }, + "runtime": { + "lib/netstandard2.0/System.Threading.Tasks.Extensions.dll": { + "assemblyVersion": "4.2.0.1", + "fileVersion": "4.6.28619.1" + } + } + }, "Vsxmd/1.4.5": {} } }, @@ -24,6 +106,62 @@ "serviceable": false, "sha512": "" }, + "Microsoft.Bcl.AsyncInterfaces/5.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-W8DPQjkMScOMTtJbPwmPyj9c3zYSFGawDW3jwlBOOsnY+EzZFLgNQ/UMkK35JmkNOVPdCyPr2Tw7Vv9N+KA3ZQ==", + "path": "microsoft.bcl.asyncinterfaces/5.0.0", + "hashPath": "microsoft.bcl.asyncinterfaces.5.0.0.nupkg.sha512" + }, + "System.Buffers/4.5.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-Rw7ijyl1qqRS0YQD/WycNst8hUUMgrMH4FCn1nNm27M4VxchZ1js3fVjQaANHO5f3sN4isvP4a+Met9Y4YomAg==", + "path": "system.buffers/4.5.1", + "hashPath": "system.buffers.4.5.1.nupkg.sha512" + }, + "System.Memory/4.5.4": { + "type": "package", + "serviceable": true, + "sha512": "sha512-1MbJTHS1lZ4bS4FmsJjnuGJOu88ZzTT2rLvrhW7Ygic+pC0NWA+3hgAen0HRdsocuQXCkUTdFn9yHJJhsijDXw==", + "path": "system.memory/4.5.4", + "hashPath": "system.memory.4.5.4.nupkg.sha512" + }, + "System.Numerics.Vectors/4.5.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-QQTlPTl06J/iiDbJCiepZ4H//BVraReU4O4EoRw1U02H5TLUIT7xn3GnDp9AXPSlJUDyFs4uWjWafNX6WrAojQ==", + "path": "system.numerics.vectors/4.5.0", + "hashPath": "system.numerics.vectors.4.5.0.nupkg.sha512" + }, + "System.Runtime.CompilerServices.Unsafe/5.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-ZD9TMpsmYJLrxbbmdvhwt9YEgG5WntEnZ/d1eH8JBX9LBp+Ju8BSBhUGbZMNVHHomWo2KVImJhTDl2hIgw/6MA==", + "path": "system.runtime.compilerservices.unsafe/5.0.0", + "hashPath": "system.runtime.compilerservices.unsafe.5.0.0.nupkg.sha512" + }, + "System.Text.Encodings.Web/5.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-KmJ+CJXizDofbq6mpqDoRRLcxgOd2z9X3XoFNULSbvbqVRZkFX3istvr+MUjL6Zw1RT+RNdoI4GYidIINtgvqQ==", + "path": "system.text.encodings.web/5.0.1", + "hashPath": "system.text.encodings.web.5.0.1.nupkg.sha512" + }, + "System.Text.Json/5.0.2": { + "type": "package", + "serviceable": true, + "sha512": "sha512-I47dVIGiV6SfAyppphxqupertT/5oZkYLDCX6vC3HpOI4ZLjyoKAreUoem2ie6G0RbRuFrlqz/PcTQjfb2DOfQ==", + "path": "system.text.json/5.0.2", + "hashPath": "system.text.json.5.0.2.nupkg.sha512" + }, + "System.Threading.Tasks.Extensions/4.5.4": { + "type": "package", + "serviceable": true, + "sha512": "sha512-zteT+G8xuGu6mS+mzDzYXbzS7rd3K6Fjb9RiZlYlJPam2/hU7JCBZBVEcywNuR+oZ1ncTvc/cq0faRr3P01OVg==", + "path": "system.threading.tasks.extensions/4.5.4", + "hashPath": "system.threading.tasks.extensions.4.5.4.nupkg.sha512" + }, "Vsxmd/1.4.5": { "type": "package", "serviceable": true, diff --git a/Stone_Red-C-Sharp-Utilities/bin/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.dll b/Stone_Red-C-Sharp-Utilities/bin/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.dll index 486c934..e09343f 100644 Binary files a/Stone_Red-C-Sharp-Utilities/bin/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.dll and b/Stone_Red-C-Sharp-Utilities/bin/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.dll differ diff --git a/Stone_Red-C-Sharp-Utilities/bin/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.pdb b/Stone_Red-C-Sharp-Utilities/bin/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.pdb index c5fbffd..94ce8e7 100644 Binary files a/Stone_Red-C-Sharp-Utilities/bin/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.pdb and b/Stone_Red-C-Sharp-Utilities/bin/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.pdb differ diff --git a/Stone_Red-C-Sharp-Utilities/bin/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.xml b/Stone_Red-C-Sharp-Utilities/bin/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.xml index c9d38f6..b12a07a 100644 --- a/Stone_Red-C-Sharp-Utilities/bin/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.xml +++ b/Stone_Red-C-Sharp-Utilities/bin/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.xml @@ -6,7 +6,7 @@ - Extentions + Extensions @@ -44,7 +44,7 @@ - The default representaion of the table + The default representation of the table @@ -54,17 +54,17 @@ - The alternative representaion of the table + The alternative representation of the table - The list representaion of the table + The list representation of the table - and Extentions + and Extensions @@ -85,7 +85,7 @@ - Extentions + Extensions @@ -102,12 +102,18 @@ - + Suspends execution of the current method until the user presses a key - - + The key that has to be pressed + The message that will be displayed + + + + Suspends execution of the current method until the user presses a key + + The message that will be displayed @@ -143,8 +149,8 @@ Creates a new rectangle instance - - + The length of the rectangle + The width of the rectangle @@ -204,7 +210,7 @@ - Multiplys the two nums + Multiples the two nums @@ -306,7 +312,7 @@ - Multiplys the two nums + Multiples the two nums @@ -471,7 +477,7 @@ - Multiplys the two nums + Multiples the two nums @@ -552,7 +558,7 @@ - Multiplys the two nums + Multiples the two nums @@ -633,7 +639,7 @@ - Multiplys the two nums + Multiples the two nums @@ -714,7 +720,7 @@ - Multiplys the two nums + Multiples the two nums @@ -863,7 +869,7 @@ - The onsole color of the log message. + The console color of the log message. @@ -878,7 +884,7 @@ - Foramt configuration. + Format configuration. @@ -1047,7 +1053,7 @@ - Extentions + Extensions @@ -1100,7 +1106,7 @@ - Extentions + Extensions @@ -1169,7 +1175,7 @@ - Revoves all whitespaces from the specified + Removes all white spaces from the specified diff --git a/Stone_Red-C-Sharp-Utilities/obj/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.assets.cache b/Stone_Red-C-Sharp-Utilities/obj/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.assets.cache index 222f053..f08e23c 100644 Binary files a/Stone_Red-C-Sharp-Utilities/obj/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.assets.cache and b/Stone_Red-C-Sharp-Utilities/obj/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.assets.cache differ diff --git a/Stone_Red-C-Sharp-Utilities/obj/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.csproj.CoreCompileInputs.cache b/Stone_Red-C-Sharp-Utilities/obj/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.csproj.CoreCompileInputs.cache index 64a62aa..4e282eb 100644 --- a/Stone_Red-C-Sharp-Utilities/obj/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.csproj.CoreCompileInputs.cache +++ b/Stone_Red-C-Sharp-Utilities/obj/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.csproj.CoreCompileInputs.cache @@ -1 +1 @@ -51e61123768d6c5b1a0a6d92b017f369b83c2cff +0c75136f6dd794dbf85e7046a00288f29b7694af diff --git a/Stone_Red-C-Sharp-Utilities/obj/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.dll b/Stone_Red-C-Sharp-Utilities/obj/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.dll index 486c934..e09343f 100644 Binary files a/Stone_Red-C-Sharp-Utilities/obj/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.dll and b/Stone_Red-C-Sharp-Utilities/obj/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.dll differ diff --git a/Stone_Red-C-Sharp-Utilities/obj/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.pdb b/Stone_Red-C-Sharp-Utilities/obj/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.pdb index c5fbffd..94ce8e7 100644 Binary files a/Stone_Red-C-Sharp-Utilities/obj/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.pdb and b/Stone_Red-C-Sharp-Utilities/obj/Release/netstandard2.1/Stone_Red-C-Sharp-Utilities.pdb differ diff --git a/Stone_Red-C-Sharp-Utilities/obj/Stone_Red-C-Sharp-Utilities.csproj.nuget.dgspec.json b/Stone_Red-C-Sharp-Utilities/obj/Stone_Red-C-Sharp-Utilities.csproj.nuget.dgspec.json index 81055d7..b3371ad 100644 --- a/Stone_Red-C-Sharp-Utilities/obj/Stone_Red-C-Sharp-Utilities.csproj.nuget.dgspec.json +++ b/Stone_Red-C-Sharp-Utilities/obj/Stone_Red-C-Sharp-Utilities.csproj.nuget.dgspec.json @@ -45,6 +45,10 @@ "netstandard2.1": { "targetAlias": "netstandard2.1", "dependencies": { + "System.Text.Json": { + "target": "Package", + "version": "[5.0.2, )" + }, "Vsxmd": { "include": "Runtime, Build, Native, ContentFiles, Analyzers, BuildTransitive", "suppressParent": "All", @@ -67,7 +71,7 @@ "privateAssets": "all" } }, - "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\5.0.401\\RuntimeIdentifierGraph.json" + "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\5.0.402\\RuntimeIdentifierGraph.json" } } } diff --git a/Stone_Red-C-Sharp-Utilities/obj/project.assets.json b/Stone_Red-C-Sharp-Utilities/obj/project.assets.json index 259c15b..23b0f9b 100644 --- a/Stone_Red-C-Sharp-Utilities/obj/project.assets.json +++ b/Stone_Red-C-Sharp-Utilities/obj/project.assets.json @@ -2,6 +2,95 @@ "version": 3, "targets": { ".NETStandard,Version=v2.1": { + "Microsoft.Bcl.AsyncInterfaces/5.0.0": { + "type": "package", + "compile": { + "lib/netstandard2.1/Microsoft.Bcl.AsyncInterfaces.dll": {} + }, + "runtime": { + "lib/netstandard2.1/Microsoft.Bcl.AsyncInterfaces.dll": {} + } + }, + "System.Buffers/4.5.1": { + "type": "package", + "compile": { + "ref/netstandard2.0/System.Buffers.dll": {} + }, + "runtime": { + "lib/netstandard2.0/System.Buffers.dll": {} + } + }, + "System.Memory/4.5.4": { + "type": "package", + "dependencies": { + "System.Buffers": "4.5.1", + "System.Numerics.Vectors": "4.4.0", + "System.Runtime.CompilerServices.Unsafe": "4.5.3" + }, + "compile": { + "lib/netstandard2.0/System.Memory.dll": {} + }, + "runtime": { + "lib/netstandard2.0/System.Memory.dll": {} + } + }, + "System.Numerics.Vectors/4.5.0": { + "type": "package", + "compile": { + "ref/netstandard2.0/System.Numerics.Vectors.dll": {} + }, + "runtime": { + "lib/netstandard2.0/System.Numerics.Vectors.dll": {} + } + }, + "System.Runtime.CompilerServices.Unsafe/5.0.0": { + "type": "package", + "compile": { + "ref/netstandard2.1/System.Runtime.CompilerServices.Unsafe.dll": {} + }, + "runtime": { + "lib/netstandard2.0/System.Runtime.CompilerServices.Unsafe.dll": {} + } + }, + "System.Text.Encodings.Web/5.0.1": { + "type": "package", + "compile": { + "lib/netstandard2.1/System.Text.Encodings.Web.dll": {} + }, + "runtime": { + "lib/netstandard2.1/System.Text.Encodings.Web.dll": {} + } + }, + "System.Text.Json/5.0.2": { + "type": "package", + "dependencies": { + "Microsoft.Bcl.AsyncInterfaces": "5.0.0", + "System.Buffers": "4.5.1", + "System.Memory": "4.5.4", + "System.Numerics.Vectors": "4.5.0", + "System.Runtime.CompilerServices.Unsafe": "5.0.0", + "System.Text.Encodings.Web": "5.0.1", + "System.Threading.Tasks.Extensions": "4.5.4" + }, + "compile": { + "lib/netstandard2.0/System.Text.Json.dll": {} + }, + "runtime": { + "lib/netstandard2.0/System.Text.Json.dll": {} + } + }, + "System.Threading.Tasks.Extensions/4.5.4": { + "type": "package", + "dependencies": { + "System.Runtime.CompilerServices.Unsafe": "4.5.3" + }, + "compile": { + "lib/netstandard2.0/System.Threading.Tasks.Extensions.dll": {} + }, + "runtime": { + "lib/netstandard2.0/System.Threading.Tasks.Extensions.dll": {} + } + }, "Vsxmd/1.4.5": { "type": "package", "build": { @@ -11,6 +100,246 @@ } }, "libraries": { + "Microsoft.Bcl.AsyncInterfaces/5.0.0": { + "sha512": "W8DPQjkMScOMTtJbPwmPyj9c3zYSFGawDW3jwlBOOsnY+EzZFLgNQ/UMkK35JmkNOVPdCyPr2Tw7Vv9N+KA3ZQ==", + "type": "package", + "path": "microsoft.bcl.asyncinterfaces/5.0.0", + "files": [ + ".nupkg.metadata", + ".signature.p7s", + "Icon.png", + "LICENSE.TXT", + "THIRD-PARTY-NOTICES.TXT", + "lib/net461/Microsoft.Bcl.AsyncInterfaces.dll", + "lib/net461/Microsoft.Bcl.AsyncInterfaces.xml", + "lib/netstandard2.0/Microsoft.Bcl.AsyncInterfaces.dll", + "lib/netstandard2.0/Microsoft.Bcl.AsyncInterfaces.xml", + "lib/netstandard2.1/Microsoft.Bcl.AsyncInterfaces.dll", + "lib/netstandard2.1/Microsoft.Bcl.AsyncInterfaces.xml", + "microsoft.bcl.asyncinterfaces.5.0.0.nupkg.sha512", + "microsoft.bcl.asyncinterfaces.nuspec", + "useSharedDesignerContext.txt", + "version.txt" + ] + }, + "System.Buffers/4.5.1": { + "sha512": "Rw7ijyl1qqRS0YQD/WycNst8hUUMgrMH4FCn1nNm27M4VxchZ1js3fVjQaANHO5f3sN4isvP4a+Met9Y4YomAg==", + "type": "package", + "path": "system.buffers/4.5.1", + "files": [ + ".nupkg.metadata", + ".signature.p7s", + "LICENSE.TXT", + "THIRD-PARTY-NOTICES.TXT", + "lib/net461/System.Buffers.dll", + "lib/net461/System.Buffers.xml", + "lib/netcoreapp2.0/_._", + "lib/netstandard1.1/System.Buffers.dll", + "lib/netstandard1.1/System.Buffers.xml", + "lib/netstandard2.0/System.Buffers.dll", + "lib/netstandard2.0/System.Buffers.xml", + "lib/uap10.0.16299/_._", + "ref/net45/System.Buffers.dll", + "ref/net45/System.Buffers.xml", + "ref/netcoreapp2.0/_._", + "ref/netstandard1.1/System.Buffers.dll", + "ref/netstandard1.1/System.Buffers.xml", + "ref/netstandard2.0/System.Buffers.dll", + "ref/netstandard2.0/System.Buffers.xml", + "ref/uap10.0.16299/_._", + "system.buffers.4.5.1.nupkg.sha512", + "system.buffers.nuspec", + "useSharedDesignerContext.txt", + "version.txt" + ] + }, + "System.Memory/4.5.4": { + "sha512": "1MbJTHS1lZ4bS4FmsJjnuGJOu88ZzTT2rLvrhW7Ygic+pC0NWA+3hgAen0HRdsocuQXCkUTdFn9yHJJhsijDXw==", + "type": "package", + "path": "system.memory/4.5.4", + "files": [ + ".nupkg.metadata", + ".signature.p7s", + "LICENSE.TXT", + "THIRD-PARTY-NOTICES.TXT", + "lib/net461/System.Memory.dll", + "lib/net461/System.Memory.xml", + "lib/netcoreapp2.1/_._", + "lib/netstandard1.1/System.Memory.dll", + "lib/netstandard1.1/System.Memory.xml", + "lib/netstandard2.0/System.Memory.dll", + "lib/netstandard2.0/System.Memory.xml", + "ref/netcoreapp2.1/_._", + "system.memory.4.5.4.nupkg.sha512", + "system.memory.nuspec", + "useSharedDesignerContext.txt", + "version.txt" + ] + }, + "System.Numerics.Vectors/4.5.0": { + "sha512": "QQTlPTl06J/iiDbJCiepZ4H//BVraReU4O4EoRw1U02H5TLUIT7xn3GnDp9AXPSlJUDyFs4uWjWafNX6WrAojQ==", + "type": "package", + "path": "system.numerics.vectors/4.5.0", + "files": [ + ".nupkg.metadata", + ".signature.p7s", + "LICENSE.TXT", + "THIRD-PARTY-NOTICES.TXT", + "lib/MonoAndroid10/_._", + "lib/MonoTouch10/_._", + "lib/net46/System.Numerics.Vectors.dll", + "lib/net46/System.Numerics.Vectors.xml", + "lib/netcoreapp2.0/_._", + "lib/netstandard1.0/System.Numerics.Vectors.dll", + "lib/netstandard1.0/System.Numerics.Vectors.xml", + "lib/netstandard2.0/System.Numerics.Vectors.dll", + "lib/netstandard2.0/System.Numerics.Vectors.xml", + "lib/portable-net45+win8+wp8+wpa81/System.Numerics.Vectors.dll", + "lib/portable-net45+win8+wp8+wpa81/System.Numerics.Vectors.xml", + "lib/uap10.0.16299/_._", + "lib/xamarinios10/_._", + "lib/xamarinmac20/_._", + "lib/xamarintvos10/_._", + "lib/xamarinwatchos10/_._", + "ref/MonoAndroid10/_._", + "ref/MonoTouch10/_._", + "ref/net45/System.Numerics.Vectors.dll", + "ref/net45/System.Numerics.Vectors.xml", + "ref/net46/System.Numerics.Vectors.dll", + "ref/net46/System.Numerics.Vectors.xml", + "ref/netcoreapp2.0/_._", + "ref/netstandard1.0/System.Numerics.Vectors.dll", + "ref/netstandard1.0/System.Numerics.Vectors.xml", + "ref/netstandard2.0/System.Numerics.Vectors.dll", + "ref/netstandard2.0/System.Numerics.Vectors.xml", + "ref/uap10.0.16299/_._", + "ref/xamarinios10/_._", + "ref/xamarinmac20/_._", + "ref/xamarintvos10/_._", + "ref/xamarinwatchos10/_._", + "system.numerics.vectors.4.5.0.nupkg.sha512", + "system.numerics.vectors.nuspec", + "useSharedDesignerContext.txt", + "version.txt" + ] + }, + "System.Runtime.CompilerServices.Unsafe/5.0.0": { + "sha512": "ZD9TMpsmYJLrxbbmdvhwt9YEgG5WntEnZ/d1eH8JBX9LBp+Ju8BSBhUGbZMNVHHomWo2KVImJhTDl2hIgw/6MA==", + "type": "package", + "path": "system.runtime.compilerservices.unsafe/5.0.0", + "files": [ + ".nupkg.metadata", + ".signature.p7s", + "Icon.png", + "LICENSE.TXT", + "THIRD-PARTY-NOTICES.TXT", + "lib/net45/System.Runtime.CompilerServices.Unsafe.dll", + "lib/net45/System.Runtime.CompilerServices.Unsafe.xml", + "lib/netcoreapp2.0/System.Runtime.CompilerServices.Unsafe.dll", + "lib/netcoreapp2.0/System.Runtime.CompilerServices.Unsafe.xml", + "lib/netstandard1.0/System.Runtime.CompilerServices.Unsafe.dll", + "lib/netstandard1.0/System.Runtime.CompilerServices.Unsafe.xml", + "lib/netstandard2.0/System.Runtime.CompilerServices.Unsafe.dll", + "lib/netstandard2.0/System.Runtime.CompilerServices.Unsafe.xml", + "ref/net461/System.Runtime.CompilerServices.Unsafe.dll", + "ref/net461/System.Runtime.CompilerServices.Unsafe.xml", + "ref/netstandard1.0/System.Runtime.CompilerServices.Unsafe.dll", + "ref/netstandard1.0/System.Runtime.CompilerServices.Unsafe.xml", + "ref/netstandard2.0/System.Runtime.CompilerServices.Unsafe.dll", + "ref/netstandard2.0/System.Runtime.CompilerServices.Unsafe.xml", + "ref/netstandard2.1/System.Runtime.CompilerServices.Unsafe.dll", + "ref/netstandard2.1/System.Runtime.CompilerServices.Unsafe.xml", + "system.runtime.compilerservices.unsafe.5.0.0.nupkg.sha512", + "system.runtime.compilerservices.unsafe.nuspec", + "useSharedDesignerContext.txt", + "version.txt" + ] + }, + "System.Text.Encodings.Web/5.0.1": { + "sha512": "KmJ+CJXizDofbq6mpqDoRRLcxgOd2z9X3XoFNULSbvbqVRZkFX3istvr+MUjL6Zw1RT+RNdoI4GYidIINtgvqQ==", + "type": "package", + "path": "system.text.encodings.web/5.0.1", + "files": [ + ".nupkg.metadata", + ".signature.p7s", + "Icon.png", + "LICENSE.TXT", + "THIRD-PARTY-NOTICES.TXT", + "lib/net461/System.Text.Encodings.Web.dll", + "lib/net461/System.Text.Encodings.Web.xml", + "lib/netcoreapp3.0/System.Text.Encodings.Web.dll", + "lib/netcoreapp3.0/System.Text.Encodings.Web.xml", + "lib/netstandard1.0/System.Text.Encodings.Web.dll", + "lib/netstandard1.0/System.Text.Encodings.Web.xml", + "lib/netstandard2.0/System.Text.Encodings.Web.dll", + "lib/netstandard2.0/System.Text.Encodings.Web.xml", + "lib/netstandard2.1/System.Text.Encodings.Web.dll", + "lib/netstandard2.1/System.Text.Encodings.Web.xml", + "system.text.encodings.web.5.0.1.nupkg.sha512", + "system.text.encodings.web.nuspec", + "useSharedDesignerContext.txt", + "version.txt" + ] + }, + "System.Text.Json/5.0.2": { + "sha512": "I47dVIGiV6SfAyppphxqupertT/5oZkYLDCX6vC3HpOI4ZLjyoKAreUoem2ie6G0RbRuFrlqz/PcTQjfb2DOfQ==", + "type": "package", + "path": "system.text.json/5.0.2", + "files": [ + ".nupkg.metadata", + ".signature.p7s", + "Icon.png", + "LICENSE.TXT", + "THIRD-PARTY-NOTICES.TXT", + "lib/net461/System.Text.Json.dll", + "lib/net461/System.Text.Json.xml", + "lib/netcoreapp3.0/System.Text.Json.dll", + "lib/netcoreapp3.0/System.Text.Json.xml", + "lib/netstandard2.0/System.Text.Json.dll", + "lib/netstandard2.0/System.Text.Json.xml", + "system.text.json.5.0.2.nupkg.sha512", + "system.text.json.nuspec", + "useSharedDesignerContext.txt", + "version.txt" + ] + }, + "System.Threading.Tasks.Extensions/4.5.4": { + "sha512": "zteT+G8xuGu6mS+mzDzYXbzS7rd3K6Fjb9RiZlYlJPam2/hU7JCBZBVEcywNuR+oZ1ncTvc/cq0faRr3P01OVg==", + "type": "package", + "path": "system.threading.tasks.extensions/4.5.4", + "files": [ + ".nupkg.metadata", + ".signature.p7s", + "LICENSE.TXT", + "THIRD-PARTY-NOTICES.TXT", + "lib/MonoAndroid10/_._", + "lib/MonoTouch10/_._", + "lib/net461/System.Threading.Tasks.Extensions.dll", + "lib/net461/System.Threading.Tasks.Extensions.xml", + "lib/netcoreapp2.1/_._", + "lib/netstandard1.0/System.Threading.Tasks.Extensions.dll", + "lib/netstandard1.0/System.Threading.Tasks.Extensions.xml", + "lib/netstandard2.0/System.Threading.Tasks.Extensions.dll", + "lib/netstandard2.0/System.Threading.Tasks.Extensions.xml", + "lib/portable-net45+win8+wp8+wpa81/System.Threading.Tasks.Extensions.dll", + "lib/portable-net45+win8+wp8+wpa81/System.Threading.Tasks.Extensions.xml", + "lib/xamarinios10/_._", + "lib/xamarinmac20/_._", + "lib/xamarintvos10/_._", + "lib/xamarinwatchos10/_._", + "ref/MonoAndroid10/_._", + "ref/MonoTouch10/_._", + "ref/netcoreapp2.1/_._", + "ref/xamarinios10/_._", + "ref/xamarinmac20/_._", + "ref/xamarintvos10/_._", + "ref/xamarinwatchos10/_._", + "system.threading.tasks.extensions.4.5.4.nupkg.sha512", + "system.threading.tasks.extensions.nuspec", + "useSharedDesignerContext.txt", + "version.txt" + ] + }, "Vsxmd/1.4.5": { "sha512": "mvTZKIhKUFvcjYv/p9dxgSFHrAlNFIemT3ai1XAFV4yJYGu/6e73NgzfHwhDi0QevuYURVdd+p088CG6KQFENg==", "type": "package", @@ -33,6 +362,7 @@ }, "projectFileDependencyGroups": { ".NETStandard,Version=v2.1": [ + "System.Text.Json >= 5.0.2", "Vsxmd >= 1.4.5" ] }, @@ -81,6 +411,10 @@ "netstandard2.1": { "targetAlias": "netstandard2.1", "dependencies": { + "System.Text.Json": { + "target": "Package", + "version": "[5.0.2, )" + }, "Vsxmd": { "include": "Runtime, Build, Native, ContentFiles, Analyzers, BuildTransitive", "suppressParent": "All", @@ -103,7 +437,7 @@ "privateAssets": "all" } }, - "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\5.0.401\\RuntimeIdentifierGraph.json" + "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\5.0.402\\RuntimeIdentifierGraph.json" } } } diff --git a/Stone_Red-C-Sharp-Utilities/obj/project.nuget.cache b/Stone_Red-C-Sharp-Utilities/obj/project.nuget.cache index afb8b04..0eaaca1 100644 --- a/Stone_Red-C-Sharp-Utilities/obj/project.nuget.cache +++ b/Stone_Red-C-Sharp-Utilities/obj/project.nuget.cache @@ -1,9 +1,17 @@ { "version": 2, - "dgSpecHash": "szJPtVin5IzkXVU9ObH6EXYb2PHQ5ZOfTN/fz6Vsz068SnBXJvLOMYWPHTw47eLiq1vQxy3andOX2PcxdtU8Uw==", + "dgSpecHash": "1TRQqM2Lc6VQODtNIvR4tlt0458C4el0swb69xSWBGEPSXqZgM3dmkQtkKkJZmNQdU3GNIfGAARCjF62Mni2uw==", "success": true, "projectFilePath": "C:\\Users\\David\\Programmieren\\Stone_Red-C-Sharp-Utilities\\Stone_Red-C-Sharp-Utilities\\Stone_Red-C-Sharp-Utilities.csproj", "expectedPackageFiles": [ + "C:\\Users\\David\\.nuget\\packages\\microsoft.bcl.asyncinterfaces\\5.0.0\\microsoft.bcl.asyncinterfaces.5.0.0.nupkg.sha512", + "C:\\Users\\David\\.nuget\\packages\\system.buffers\\4.5.1\\system.buffers.4.5.1.nupkg.sha512", + "C:\\Users\\David\\.nuget\\packages\\system.memory\\4.5.4\\system.memory.4.5.4.nupkg.sha512", + "C:\\Users\\David\\.nuget\\packages\\system.numerics.vectors\\4.5.0\\system.numerics.vectors.4.5.0.nupkg.sha512", + "C:\\Users\\David\\.nuget\\packages\\system.runtime.compilerservices.unsafe\\5.0.0\\system.runtime.compilerservices.unsafe.5.0.0.nupkg.sha512", + "C:\\Users\\David\\.nuget\\packages\\system.text.encodings.web\\5.0.1\\system.text.encodings.web.5.0.1.nupkg.sha512", + "C:\\Users\\David\\.nuget\\packages\\system.text.json\\5.0.2\\system.text.json.5.0.2.nupkg.sha512", + "C:\\Users\\David\\.nuget\\packages\\system.threading.tasks.extensions\\4.5.4\\system.threading.tasks.extensions.4.5.4.nupkg.sha512", "C:\\Users\\David\\.nuget\\packages\\vsxmd\\1.4.5\\vsxmd.1.4.5.nupkg.sha512" ], "logs": []