Class MessageContent
Content of m.room.message.
Implements
Inherited Members
Namespace: Uniform.Matrix.Protocol.Core
Assembly: Uniform.Matrix.Protocol.Core.dll
Syntax
public sealed record MessageContent : IEquatable<MessageContent>
Properties
| Edit this page View SourceBody
Plain text body; fallback for every message type.
Declaration
public string? Body { get; init; }
Property Value
| Type | Description |
|---|---|
| string |
File
Attachment in an encrypted room, instead of Url.
Declaration
public EncryptedFile? File { get; init; }
Property Value
| Type | Description |
|---|---|
| EncryptedFile |
Filename
Original file name of an attachment when Body is a caption.
Declaration
public string? Filename { get; init; }
Property Value
| Type | Description |
|---|---|
| string |
Format
Format of FormattedBody, usually org.matrix.custom.html.
Declaration
public string? Format { get; init; }
Property Value
| Type | Description |
|---|---|
| string |
FormattedBody
Formatted body, e.g. HTML.
Declaration
public string? FormattedBody { get; init; }
Property Value
| Type | Description |
|---|---|
| string |
Info
Metadata of an attachment.
Declaration
public MediaInfo? Info { get; init; }
Property Value
| Type | Description |
|---|---|
| MediaInfo |
MediaUrl
Declaration
[JsonIgnore]
public string? MediaUrl { get; }
Property Value
| Type | Description |
|---|---|
| string |
Mentions
Users and room mentioned; when set, servers notify only these instead of matching the body.
Declaration
[JsonPropertyName("m.mentions")]
public Mentions? Mentions { get; init; }
Property Value
| Type | Description |
|---|---|
| Mentions |
MessageType
Message type, see MessageTypes.
Declaration
[JsonPropertyName("msgtype")]
public string? MessageType { get; init; }
Property Value
| Type | Description |
|---|---|
| string |
NewContent
Replacement content of an edit.
Declaration
[JsonPropertyName("m.new_content")]
public MessageContent? NewContent { get; init; }
Property Value
| Type | Description |
|---|---|
| MessageContent |
RelatesTo
Relation to another event, e.g. reply or edits.
Declaration
[JsonPropertyName("m.relates_to")]
public Relation? RelatesTo { get; init; }
Property Value
| Type | Description |
|---|---|
| Relation |
Url
Content URI of an attachment in an unencrypted room.
Declaration
public string? Url { get; init; }
Property Value
| Type | Description |
|---|---|
| string |