Docs · API reference · Motus.Abstractions

FilePayload Class#

Represents a file to be uploaded via a file chooser.

public sealed record FilePayload : System.IEquatable<Motus.Abstractions.FilePayload>

Inheritance System.Object → FilePayload

Implements System.IEquatable<FilePayload>

Constructors#

FilePayload(string, string, byte[]) Constructor#

Represents a file to be uploaded via a file chooser.

public FilePayload(string Name, string MimeType, byte[] Buffer);

Parameters#

Name System.String

The file name.

MimeType System.String

The MIME type of the file.

Buffer System.Byte[]

The file content as a byte array.

Properties#

Buffer Property#

The file content as a byte array.

public byte[] Buffer { get; init; }

Property Value#

System.Byte[]

MimeType Property#

The MIME type of the file.

public string MimeType { get; init; }

Property Value#

System.String

Name Property#

The file name.

public string Name { get; init; }

Property Value#

System.String