about summary refs log tree commit diff
path: root/MatrixContentFilter/MatrixContentFilterConfiguration.cs
diff options
context:
space:
mode:
authorRory& <root@rory.gay>2024-10-04 19:51:44 +0200
committerRory& <root@rory.gay>2024-10-04 19:51:44 +0200
commitc8f7ef7c1d2bd705a5442c0dc591b8e5a50673a5 (patch)
tree9b951c6e2c120ec370ce8318238aadbdda880a89 /MatrixContentFilter/MatrixContentFilterConfiguration.cs
downloadMatrixContentFilter-master.tar.xz
Initial commit HEAD master
Diffstat (limited to 'MatrixContentFilter/MatrixContentFilterConfiguration.cs')
-rw-r--r--MatrixContentFilter/MatrixContentFilterConfiguration.cs18
1 files changed, 18 insertions, 0 deletions
diff --git a/MatrixContentFilter/MatrixContentFilterConfiguration.cs b/MatrixContentFilter/MatrixContentFilterConfiguration.cs
new file mode 100644
index 0000000..57537f0
--- /dev/null
+++ b/MatrixContentFilter/MatrixContentFilterConfiguration.cs
@@ -0,0 +1,18 @@
+using Microsoft.Extensions.Configuration;
+
+namespace MatrixContentFilter;
+
+public class MatrixContentFilterConfiguration {
+    public MatrixContentFilterConfiguration(IConfiguration config) => config.GetRequiredSection("MatrixContentFilter").Bind(this);
+
+    public List<string> Admins { get; set; } = new();
+    public ConcurrencyLimitsConfiguration ConcurrencyLimits { get; set; } = new();
+    
+    public string AppMode { get; set; } = "bot";
+    public string AsyncQueueImplementation { get; set; } = "lifo";
+    
+    public class ConcurrencyLimitsConfiguration {
+        public int Redactions { get; set; } = 1;
+        public int LogMessages { get; set; } = 1;
+    }
+}