Table of Contents

Struct ImageProperties

Namespace
NetCord.Rest
Assembly
NetCord.dll
[JsonConverter(typeof(ImageProperties.ImagePropertiesConverter))]
public struct ImageProperties
Inherited Members

Constructors

ImageProperties(ImageFormat, ReadOnlyMemory<byte>, bool)

public ImageProperties(ImageFormat format, ReadOnlyMemory<byte> data, bool isBase64 = false)

Parameters

format ImageFormat

The format of the image.

data ReadOnlyMemory<byte>

The data of the image.

isBase64 bool

Whether data is in Base64 format.

Properties

Data

The data of the image.

public ReadOnlyMemory<byte> Data { readonly get; set; }

Property Value

ReadOnlyMemory<byte>

Empty

An empty ImageProperties instance.

public static ImageProperties Empty { get; }

Property Value

ImageProperties

Format

The format of the image.

public ImageFormat Format { readonly get; set; }

Property Value

ImageFormat

IsBase64

Whether Data is in Base64 format.

public bool IsBase64 { readonly get; set; }

Property Value

bool

Methods

WithData(ReadOnlyMemory<byte>)

The data of the image.

public ImageProperties WithData(ReadOnlyMemory<byte> data)

Parameters

data ReadOnlyMemory<byte>

Returns

ImageProperties

WithFormat(ImageFormat)

The format of the image.

public ImageProperties WithFormat(ImageFormat format)

Parameters

format ImageFormat

Returns

ImageProperties

WithIsBase64(bool)

Whether Data is in Base64 format.

public ImageProperties WithIsBase64(bool isBase64 = true)

Parameters

isBase64 bool

Returns

ImageProperties