Table of Contents

Struct Modality

Namespace
Google.GenAI.Types
Assembly
Google.GenAI.dll

Server content modalities.

[JsonConverter(typeof(ModalityConverter))]
public readonly record struct Modality : IEquatable<Modality>
Implements
Inherited Members

Properties

AllValues

public static IReadOnlyList<Modality> AllValues { get; }

Property Value

IReadOnlyList<Modality>

Audio

Indicates the model should return audio.

public static Modality Audio { get; }

Property Value

Modality

Image

Indicates the model should return images.

public static Modality Image { get; }

Property Value

Modality

ModalityUnspecified

The modality is unspecified.

public static Modality ModalityUnspecified { get; }

Property Value

Modality

Text

Indicates the model should return text

public static Modality Text { get; }

Property Value

Modality

Value

public string Value { get; }

Property Value

string

Video

Indicates the model should return video.

public static Modality Video { get; }

Property Value

Modality

Methods

Equals(Modality)

public bool Equals(Modality other)

Parameters

other Modality

Returns

bool

FromString(string)

public static Modality FromString(string value)

Parameters

value string

Returns

Modality

GetHashCode()

public override int GetHashCode()

Returns

int

ToString()

public override string ToString()

Returns

string

Operators

implicit operator Modality(string)

public static implicit operator Modality(string value)

Parameters

value string

Returns

Modality