Share via


AudioContent Constructors

Definition

Overloads

AudioContent(ReadOnlyMemory<Byte>, String)

Initializes a new instance of the AudioContent class.

AudioContent(String, String)

Initializes a new instance of the AudioContent class.

AudioContent(Uri, String)

Initializes a new instance of the AudioContent class.

AudioContent(ReadOnlyMemory<Byte>, String)

Initializes a new instance of the AudioContent class.

public AudioContent (ReadOnlyMemory<byte> data, string? mediaType = default);
new Microsoft.Extensions.AI.AudioContent : ReadOnlyMemory<byte> * string -> Microsoft.Extensions.AI.AudioContent
Public Sub New (data As ReadOnlyMemory(Of Byte), Optional mediaType As String = Nothing)

Parameters

data
ReadOnlyMemory<Byte>

The byte contents.

mediaType
String

The media type (also known as MIME type) represented by the content.

Applies to

AudioContent(String, String)

Initializes a new instance of the AudioContent class.

[System.Text.Json.Serialization.JsonConstructor]
public AudioContent (string uri, string? mediaType = default);
[<System.Text.Json.Serialization.JsonConstructor>]
new Microsoft.Extensions.AI.AudioContent : string * string -> Microsoft.Extensions.AI.AudioContent
Public Sub New (uri As String, Optional mediaType As String = Nothing)

Parameters

uri
String

The URI of the content. This may be a data URI.

mediaType
String

The media type (also known as MIME type) represented by the content.

Attributes

Applies to

AudioContent(Uri, String)

Initializes a new instance of the AudioContent class.

public AudioContent (Uri uri, string? mediaType = default);
new Microsoft.Extensions.AI.AudioContent : Uri * string -> Microsoft.Extensions.AI.AudioContent
Public Sub New (uri As Uri, Optional mediaType As String = Nothing)

Parameters

uri
Uri

The URI of the content. This may be a data URI.

mediaType
String

The media type (also known as MIME type) represented by the content.

Applies to