diff options
author | TheArcaneBrony <myrainbowdash949@gmail.com> | 2023-09-04 02:18:47 +0200 |
---|---|---|
committer | TheArcaneBrony <myrainbowdash949@gmail.com> | 2023-09-04 02:18:47 +0200 |
commit | 7e40421d0eaee613be5b807502eb25fafebde5b1 (patch) | |
tree | af84e4c39fd0c3cfa05e1b66fb566d5cda59607f /MxApiExtensions.Classes.LibMatrix/RoomInfoEntry.cs | |
parent | Code cleanup (diff) | |
download | MxApiExtensions-7e40421d0eaee613be5b807502eb25fafebde5b1.tar.xz |
Added a lot of utilities
Diffstat (limited to 'MxApiExtensions.Classes.LibMatrix/RoomInfoEntry.cs')
-rw-r--r-- | MxApiExtensions.Classes.LibMatrix/RoomInfoEntry.cs | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/MxApiExtensions.Classes.LibMatrix/RoomInfoEntry.cs b/MxApiExtensions.Classes.LibMatrix/RoomInfoEntry.cs new file mode 100644 index 0000000..6ea188e --- /dev/null +++ b/MxApiExtensions.Classes.LibMatrix/RoomInfoEntry.cs @@ -0,0 +1,20 @@ +using System.Text.Json.Serialization; +using LibMatrix.Responses; + +namespace LibMatrix.MxApiExtensions; + +/// <summary> +/// Generic room info, this will most likely be out of date due to caching! +/// This is only useful for giving a rough idea of the room state. +/// </summary> +public class RoomInfoEntry { + public string RoomId { get; set; } + public List<StateEventResponse?> RoomState { get; set; } + + public int StateCount { get; set; } + + public Dictionary<string, int> MemberCounts { get; set; } = new(); + + // [JsonIgnore] + public DateTime ExpiresAt { get; set; } = DateTime.Now.AddMinutes(1); +} |