PowerToys/src/modules/launcher/Wox.Infrastructure/Storage/PluginJsonStorage.cs
Josh Soref 84169cce10
Spelling: ... wox (#3775)
* spelling: arguments

* spelling: config

* spelling: deactivated

* spelling: exception

* spelling: folder

* spelling: initialize

* spelling: makesure

* spelling: response

* spelling: storage

* spelling: visibility

* spelling: serialized

* spelling: zipped
2020-05-27 08:05:54 -07:00

19 lines
606 B
C#

using System.IO;
namespace Wox.Infrastructure.Storage
{
public class PluginJsonStorage<T> :JsonStorage<T> where T : new()
{
public PluginJsonStorage()
{
// C# related, add python related below
var dataType = typeof(T);
var assemblyName = typeof(T).Assembly.GetName().Name;
DirectoryPath = Path.Combine(Constant.DataDirectory, DirectoryName, Constant.Plugins, assemblyName);
Helper.ValidateDirectory(DirectoryPath);
FilePath = Path.Combine(DirectoryPath, $"{dataType.Name}{FileSuffix}");
}
}
}