diff --git a/GW2EI.sln b/GW2EI.sln index 8fa1092aee..b5e752fc8f 100644 --- a/GW2EI.sln +++ b/GW2EI.sln @@ -1,7 +1,7 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio Version 16 -VisualStudioVersion = 16.0.29319.158 +# Visual Studio Version 17 +VisualStudioVersion = 17.3.32901.215 MinimumVisualStudioVersion = 10.0.40219.1 Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "GW2EIParser", "GW2EIParser\GW2EIParser.csproj", "{6135677E-6C0E-42DE-925E-1995E52E5AC5}" EndProject @@ -22,7 +22,9 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution .editorconfig = .editorconfig EndProjectSection EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GW2EIJSON", "GW2EIJSON\GW2EIJSON.csproj", "{C30E7976-08D5-48C4-A0CD-2A8CF541162A}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "GW2EIJSON", "GW2EIJSON\GW2EIJSON.csproj", "{C30E7976-08D5-48C4-A0CD-2A8CF541162A}" +EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "GW2EIWingman", "GW2EIWingman\GW2EIWingman.csproj", "{04A96BA2-27A7-4D6B-B8F8-368EE771A3D2}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -80,6 +82,12 @@ Global {C30E7976-08D5-48C4-A0CD-2A8CF541162A}.NoRewards|Any CPU.Build.0 = Debug|Any CPU {C30E7976-08D5-48C4-A0CD-2A8CF541162A}.Release|Any CPU.ActiveCfg = Release|Any CPU {C30E7976-08D5-48C4-A0CD-2A8CF541162A}.Release|Any CPU.Build.0 = Release|Any CPU + {04A96BA2-27A7-4D6B-B8F8-368EE771A3D2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {04A96BA2-27A7-4D6B-B8F8-368EE771A3D2}.Debug|Any CPU.Build.0 = Debug|Any CPU + {04A96BA2-27A7-4D6B-B8F8-368EE771A3D2}.NoRewards|Any CPU.ActiveCfg = NoRewards|Any CPU + {04A96BA2-27A7-4D6B-B8F8-368EE771A3D2}.NoRewards|Any CPU.Build.0 = NoRewards|Any CPU + {04A96BA2-27A7-4D6B-B8F8-368EE771A3D2}.Release|Any CPU.ActiveCfg = Release|Any CPU + {04A96BA2-27A7-4D6B-B8F8-368EE771A3D2}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/GW2EIWingman/GW2EIWingman.csproj b/GW2EIWingman/GW2EIWingman.csproj new file mode 100644 index 0000000000..f606b9dc00 --- /dev/null +++ b/GW2EIWingman/GW2EIWingman.csproj @@ -0,0 +1,29 @@ + + + + netstandard2.0 + Debug;Release;NoRewards + + + + DEBUG + + + + DEBUG + + + + AllEnabledByDefault + 0.0.0 + EliphasNUIT + GW2 Elite Insights + GW2 Elite Insights + true + + + + + + + diff --git a/GW2EIWingman/WingmanController.cs b/GW2EIWingman/WingmanController.cs new file mode 100644 index 0000000000..b9aa996602 --- /dev/null +++ b/GW2EIWingman/WingmanController.cs @@ -0,0 +1,30 @@ +using System; +using System.Collections.Generic; +using System.Drawing; +using System.IO; +using System.Net; +using System.Net.Http; +using System.Threading; +using System.Threading.Tasks; +using Newtonsoft.Json; +using Newtonsoft.Json.Serialization; + +[assembly: System.CLSCompliant(false)] +namespace GW2EIWingman +{ + public static class WingmanController + { + ///////////////// URL Utilities + + private static string TestConnectionURL { get; } = "https://gw2wingman.nevermindcreations.de/testConnection"; + + private const string BaseAPIURL = "https://gw2wingman.nevermindcreations.de/api/"; + private static string EIVersionURL { get; } = BaseAPIURL + "EIversion"; + private static string ImportLogQueuedURL { get; } = BaseAPIURL + "importLogQueued"; + private static string CheckLogQueuedURL { get; } = BaseAPIURL + "checkLogQueued"; + private static string CheckLogQueuedOrDBURL { get; } = BaseAPIURL + "checkLogQueuedOrDB"; + private static string CheckUploadURL { get; } = BaseAPIURL + "checkUpload"; + private static string UploadProcessedURL { get; } = BaseAPIURL + "uploadProcessed"; + } + +} diff --git a/GW2EIWingman/WingmanUploadJsons/CheckLogQueuedObject.cs b/GW2EIWingman/WingmanUploadJsons/CheckLogQueuedObject.cs new file mode 100644 index 0000000000..a430312c69 --- /dev/null +++ b/GW2EIWingman/WingmanUploadJsons/CheckLogQueuedObject.cs @@ -0,0 +1,14 @@ +using Newtonsoft.Json; + +namespace GW2EIWingman.WingmanUploadJsons +{ + public class CheckLogQueuedObject + { + [JsonProperty] + public string Link { get; internal set; } + [JsonProperty] + public string TargetURL { get; internal set; } + [JsonProperty] + public bool InQueue { get; internal set; } + } +} diff --git a/GW2EIWingman/WingmanUploadJsons/CheckLogQueuedOrDBObject.cs b/GW2EIWingman/WingmanUploadJsons/CheckLogQueuedOrDBObject.cs new file mode 100644 index 0000000000..dc1f841570 --- /dev/null +++ b/GW2EIWingman/WingmanUploadJsons/CheckLogQueuedOrDBObject.cs @@ -0,0 +1,10 @@ +using Newtonsoft.Json; + +namespace GW2EIWingman.WingmanUploadJsons +{ + public class CheckLogQueuedOrDBObject : CheckLogQueuedObject + { + [JsonProperty] + public bool InDB { get; internal set; } + } +} diff --git a/GW2EIWingman/WingmanUploadJsons/ImportLogQueuedObject.cs b/GW2EIWingman/WingmanUploadJsons/ImportLogQueuedObject.cs new file mode 100644 index 0000000000..f96f6ab41e --- /dev/null +++ b/GW2EIWingman/WingmanUploadJsons/ImportLogQueuedObject.cs @@ -0,0 +1,14 @@ +using Newtonsoft.Json; + +namespace GW2EIWingman.WingmanUploadJsons +{ + public class ImportLogQueuedObject + { + [JsonProperty] + public string Link { get; internal set; } + [JsonProperty] + public string Note { get; internal set; } + [JsonProperty] + public int Success { get; internal set; } + } +}