Κοινή χρήση μέσω


DataContent Constructors

Definition

Overloads

DataContent(ReadOnlyMemory<Byte>, String)

Initializes a new instance of the DataContent class.

DataContent(String, String)

Initializes a new instance of the DataContent class.

DataContent(Uri, String)

Initializes a new instance of the DataContent class.

DataContent(ReadOnlyMemory<Byte>, String)

Initializes a new instance of the DataContent class.

public DataContent (ReadOnlyMemory<byte> data, string? mediaType = default);
new Microsoft.Extensions.AI.DataContent : ReadOnlyMemory<byte> * string -> Microsoft.Extensions.AI.DataContent
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

DataContent(String, String)

Initializes a new instance of the DataContent class.

[System.Text.Json.Serialization.JsonConstructor]
public DataContent (string uri, string? mediaType = default);
[<System.Text.Json.Serialization.JsonConstructor>]
new Microsoft.Extensions.AI.DataContent : string * string -> Microsoft.Extensions.AI.DataContent
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

DataContent(Uri, String)

Initializes a new instance of the DataContent class.

public DataContent (Uri uri, string? mediaType = default);
new Microsoft.Extensions.AI.DataContent : Uri * string -> Microsoft.Extensions.AI.DataContent
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