DataContent Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Represents data content, such as an image or audio.
public ref class DataContent : Microsoft::Extensions::AI::AIContent
public class DataContent : Microsoft.Extensions.AI.AIContent
type DataContent = class
inherit AIContent
Public Class DataContent
Inherits AIContent
- Inheritance
- Derived
Remarks
The represented content may either be the actual bytes stored in this instance, or it may be a URI that references the location of the content.
Uri always returns a valid URI string, even if the instance was constructed from a ReadOnlyMemory<T>. In that case, a data URI will be constructed and returned.
Constructors
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. |
Properties
AdditionalProperties |
Gets or sets additional properties for the content. (Inherited from AIContent) |
ContainsData |
Gets a value indicating whether the content contains data rather than only being a reference to data. |
Data |
Gets the data represented by this instance. |
MediaType |
Gets the media type (also known as MIME type) of the content. |
RawRepresentation |
Gets or sets the raw representation of the content from an underlying implementation. (Inherited from AIContent) |
Uri |
Gets the URI for this DataContent. |
Methods
Equals(Object) |
Determines whether the specified object is equal to the current object. (Inherited from Object) |
GetHashCode() |
Serves as the default hash function. (Inherited from Object) |
GetType() |
Gets the Type of the current instance. (Inherited from Object) |
MemberwiseClone() |
Creates a shallow copy of the current Object. (Inherited from Object) |
ToString() |
Returns a string that represents the current object. (Inherited from Object) |
Applies to
.NET