From 6cc16a0c9045acd2f9e5047b3b176a386d8f06de Mon Sep 17 00:00:00 2001 From: Anairkoen Schno Date: Fri, 6 Dec 2019 17:44:53 -0600 Subject: [PATCH] Moved JsonConfigProvider to a new namespace Added GeneratedStore --- IPA.Loader/Config/Config.cs | 2 +- .../JsonConfigProvider.cs | 2 +- IPA.Loader/Config/Stores/GeneratedStore.cs | 38 +++++++++++++++++++ IPA.Loader/IPA.Loader.csproj | 3 +- 4 files changed, 42 insertions(+), 3 deletions(-) rename IPA.Loader/Config/{ConfigProviders => Providers}/JsonConfigProvider.cs (98%) create mode 100644 IPA.Loader/Config/Stores/GeneratedStore.cs diff --git a/IPA.Loader/Config/Config.cs b/IPA.Loader/Config/Config.cs index a6f4a66c..90564ea9 100644 --- a/IPA.Loader/Config/Config.cs +++ b/IPA.Loader/Config/Config.cs @@ -3,7 +3,7 @@ using System.Collections.Generic; using System.IO; using System.Linq; using System.Reflection; -using IPA.Config.ConfigProviders; +using IPA.Config.Providers; using IPA.Utilities; #if NET3 using Net3_Proxy; diff --git a/IPA.Loader/Config/ConfigProviders/JsonConfigProvider.cs b/IPA.Loader/Config/Providers/JsonConfigProvider.cs similarity index 98% rename from IPA.Loader/Config/ConfigProviders/JsonConfigProvider.cs rename to IPA.Loader/Config/Providers/JsonConfigProvider.cs index 476c76d3..7daa9227 100644 --- a/IPA.Loader/Config/ConfigProviders/JsonConfigProvider.cs +++ b/IPA.Loader/Config/Providers/JsonConfigProvider.cs @@ -6,7 +6,7 @@ using System.Collections.Specialized; using System.ComponentModel; using System.IO; -namespace IPA.Config.ConfigProviders +namespace IPA.Config.Providers { [Config.Type("json")] internal class JsonConfigProvider : IConfigProvider diff --git a/IPA.Loader/Config/Stores/GeneratedStore.cs b/IPA.Loader/Config/Stores/GeneratedStore.cs new file mode 100644 index 00000000..d866739f --- /dev/null +++ b/IPA.Loader/Config/Stores/GeneratedStore.cs @@ -0,0 +1,38 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading; +using System.Threading.Tasks; + +namespace IPA.Config.Stores +{ + internal class GeneratedStore + { + private class Impl : IConfigStore + { + public WaitHandle SyncObject { get; private set; } = new AutoResetEvent(false); + + public ReaderWriterLockSlim WriteSyncObject => throw new NotImplementedException(); + + public void ReadFrom(IConfigProvider provider) + { + throw new NotImplementedException(); + } + + public void WriteTo(IConfigProvider provider) + { + throw new NotImplementedException(); + } + } + + public static T Create() => (T)Create(typeof(T)); + + public static IConfigStore Create(Type type) + { + + return null; + } + + } +} diff --git a/IPA.Loader/IPA.Loader.csproj b/IPA.Loader/IPA.Loader.csproj index 2bca05e3..cde1c398 100644 --- a/IPA.Loader/IPA.Loader.csproj +++ b/IPA.Loader/IPA.Loader.csproj @@ -85,7 +85,7 @@ - + @@ -93,6 +93,7 @@ +