SndModuleSettings`1.cs
1 // Copyright (c) Microsoft Corporation 2 // The Microsoft Corporation licenses this file to you under the MIT license. 3 // See the LICENSE file in the project root for more information. 4 5 using System.Text.Json; 6 using System.Text.Json.Serialization; 7 8 namespace Microsoft.PowerToys.Settings.UI.Library 9 { 10 // Represents a powertoys module settings sent to the runner. 11 public class SndModuleSettings<T> 12 { 13 [JsonPropertyName("powertoys")] 14 public T PowertoysSetting { get; set; } 15 16 public SndModuleSettings() 17 { 18 } 19 20 public SndModuleSettings(T settings) 21 { 22 PowertoysSetting = settings; 23 } 24 25 public string ToJsonString() 26 { 27 return JsonSerializer.Serialize(this); 28 } 29 } 30 }