Class RoomVersion
A room version: the rules of event format, redaction and authorization a room follows.
Namespace: Uniform.Matrix.Protocol.Server
Assembly: Uniform.Matrix.Protocol.Server.dll
public sealed record RoomVersion : IEquatable<RoomVersion>
Fields
|
Edit this page
View Source
Version 10: integer power levels, knock_restricted joins.
Declaration
public static readonly RoomVersion V10
Field Value
|
Edit this page
View Source
Version 11: the create event's sender is the creator, clarified redaction.
Declaration
public static readonly RoomVersion V11
Field Value
|
Edit this page
View Source
Version 12: the room ID is the create event's hash, and the creators have unlimited power.
Declaration
public static readonly RoomVersion V12
Field Value
Properties
|
Edit this page
View Source
Whether m.room.create must name the creator in content.creator; from version 11 the sender is the creator.
Declaration
public bool CreateHasCreator { get; init; }
Property Value
|
Edit this page
View Source
Version of new rooms unless the client asks for another.
Declaration
public static RoomVersion Default { get; }
Property Value
|
Edit this page
View Source
Declaration
public required string Id { get; init; }
Property Value
|
Edit this page
View Source
Which keys survive redaction.
Declaration
public RedactionRules Redaction { get; init; }
Property Value
|
Edit this page
View Source
Whether the room ID is ! and the create event's reference hash, the create event has no room_id and is left out of auth_events, and the creators (the sender and additional_creators) have unlimited power; from version 12.
Declaration
public bool RoomIdIsCreateHash { get; init; }
Property Value
|
Edit this page
View Source
Versions this server can create and joins, by ID.
Declaration
public static IReadOnlyDictionary<string, RoomVersion> Supported { get; }
Property Value
Methods
|
Edit this page
View Source
Return the version of ID id, or null when not supported.
Declaration
public static RoomVersion? Find(string? id)
Parameters
| Type |
Name |
Description |
| string |
id |
|
Returns
|
Edit this page
View Source
Return the room ID of a room whose create event has ID createEventId, when RoomIdIsCreateHash.
Declaration
public static string RoomIdOf(string createEventId)
Parameters
| Type |
Name |
Description |
| string |
createEventId |
|
Returns
Implements