From 1b33764088ed522c6dd7853e4dfe893f4fe540b8 Mon Sep 17 00:00:00 2001 From: Andrew Napierkowski Date: Thu, 14 Jun 2018 12:06:43 -0400 Subject: [PATCH 1/2] initial conversion test --- FantasyData.Api.Client/Clients/BaseClient.cs | 5 +- .../FantasyData.Api.Client.csproj | 322 +----------------- .../FantasyData.Api.Client.csproj.nuspec | 21 -- .../Properties/AssemblyInfo.cs | 36 -- 4 files changed, 9 insertions(+), 375 deletions(-) delete mode 100644 FantasyData.Api.Client/FantasyData.Api.Client.csproj.nuspec delete mode 100644 FantasyData.Api.Client/Properties/AssemblyInfo.cs diff --git a/FantasyData.Api.Client/Clients/BaseClient.cs b/FantasyData.Api.Client/Clients/BaseClient.cs index d06f609..839ad23 100644 --- a/FantasyData.Api.Client/Clients/BaseClient.cs +++ b/FantasyData.Api.Client/Clients/BaseClient.cs @@ -1,7 +1,7 @@ using System; using System.Collections.Generic; using System.Runtime.Serialization.Json; -using System.Web.Script.Serialization; +using Newtonsoft.Json; namespace FantasyData.Api.Client { @@ -60,8 +60,7 @@ protected T Get(string apiCall, IList> parameter // Download json, deserialize it, and return it var json = client.DownloadString(url); - var serializer = new JavaScriptSerializer() { MaxJsonLength = int.MaxValue }; - return serializer.Deserialize(json); + return JsonConvert.DeserializeObject(json); } diff --git a/FantasyData.Api.Client/FantasyData.Api.Client.csproj b/FantasyData.Api.Client/FantasyData.Api.Client.csproj index 61f01c8..afada82 100644 --- a/FantasyData.Api.Client/FantasyData.Api.Client.csproj +++ b/FantasyData.Api.Client/FantasyData.Api.Client.csproj @@ -1,319 +1,11 @@ - - - + + - Debug - AnyCPU - {4917F563-EC8F-4E15-B08A-E18B514A3960} - Library - Properties - FantasyData.Api.Client - FantasyData.Api.Client - v4.6.1 - 512 - - + netstandard2.0 - - true - full - false - bin\Debug\ - DEBUG;TRACE - prompt - 4 - false - - - pdbonly - true - bin\Release\ - TRACE - prompt - 4 - false - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - - Designer - + - - \ No newline at end of file + + diff --git a/FantasyData.Api.Client/FantasyData.Api.Client.csproj.nuspec b/FantasyData.Api.Client/FantasyData.Api.Client.csproj.nuspec deleted file mode 100644 index 2ce9177..0000000 --- a/FantasyData.Api.Client/FantasyData.Api.Client.csproj.nuspec +++ /dev/null @@ -1,21 +0,0 @@ - - - - FantasyData.Api.Client - FantasyData API Client Library - 0.2.1 - FantasyData LLC - FantasyData LLC - https://fantasydata.com/terms-of-service.aspx - https://github.com/fantasydata/fantasydata-api-csharp - https://raw.githubusercontent.com/fantasydata/fantasydata-api-csharp/master/FantasyData.Api.Client/fantasy-logo-icon-500-gray-white.png - false - FantasyData API C# Client Library - Fixed bug affecting some endpoints with large payloads. - Copyright FantasyData LLC 2018 - Fantasy Sports Live Data Feed API Client Library Wrapper SDK - - - - - \ No newline at end of file diff --git a/FantasyData.Api.Client/Properties/AssemblyInfo.cs b/FantasyData.Api.Client/Properties/AssemblyInfo.cs deleted file mode 100644 index 401d69b..0000000 --- a/FantasyData.Api.Client/Properties/AssemblyInfo.cs +++ /dev/null @@ -1,36 +0,0 @@ -using System.Reflection; -using System.Runtime.CompilerServices; -using System.Runtime.InteropServices; - -// General Information about an assembly is controlled through the following -// set of attributes. Change these attribute values to modify the information -// associated with an assembly. -[assembly: AssemblyTitle("FantasyData.Api.Client")] -[assembly: AssemblyDescription("")] -[assembly: AssemblyConfiguration("")] -[assembly: AssemblyCompany("")] -[assembly: AssemblyProduct("FantasyData.Api.Client")] -[assembly: AssemblyCopyright("Copyright © 2018")] -[assembly: AssemblyTrademark("")] -[assembly: AssemblyCulture("")] - -// Setting ComVisible to false makes the types in this assembly not visible -// to COM components. If you need to access a type in this assembly from -// COM, set the ComVisible attribute to true on that type. -[assembly: ComVisible(false)] - -// The following GUID is for the ID of the typelib if this project is exposed to COM -[assembly: Guid("4917f563-ec8f-4e15-b08a-e18b514a3960")] - -// Version information for an assembly consists of the following four values: -// -// Major Version -// Minor Version -// Build Number -// Revision -// -// You can specify all the values or you can default the Build and Revision Numbers -// by using the '*' as shown below: -// [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("1.0.0.0")] -[assembly: AssemblyFileVersion("1.0.0.0")] From 2bb1eb5152b7ba1f0c5be24e73e271bcfbd5de16 Mon Sep 17 00:00:00 2001 From: Scott Gimpel Date: Thu, 14 Jun 2018 13:37:51 -0400 Subject: [PATCH 2/2] updated gitognore --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 90841ed..52c57ce 100644 --- a/.gitignore +++ b/.gitignore @@ -10,3 +10,4 @@ /*/v15/* */.vs/* *.nupkg +*/packages/* \ No newline at end of file