Class ContentPart<T>
Base class for different types of content parts in a message. Each content part has a defined type, such as Text, Image(Url/Base64/FileId), Audio(Base64), or File(Base64/FileId).
public abstract class ContentPart<T> : ContentPart
Type Parameters
T
- Inheritance
-
objectContentPart<T>
- Derived
- Inherited Members
Constructors
ContentPart()
public ContentPart()
ContentPart(string, ContentFormat, T)
protected ContentPart(string type, ContentFormat dataType, T data)
Parameters
typestringdataTypeContentFormatdataT
Properties
Data
public T Data { get; set; }
Property Value
- T
Methods
ToString()
Indicates if the content part is in base64 format. This is true if the content part is a base64 encoded image, file, or audio.
public override string ToString()
Returns
- string
Operators
implicit operator T(ContentPart<T>)
public static implicit operator T(ContentPart<T> content)
Parameters
contentContentPart<T>
Returns
- T