Table of Contents

Class SubjectReferenceConfig

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

Configuration for a Subject reference image.

public record SubjectReferenceConfig : IEquatable<SubjectReferenceConfig>
Inheritance
SubjectReferenceConfig
Implements
Inherited Members

Properties

SubjectDescription

Subject description for the image.

[JsonPropertyName("subjectDescription")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public string? SubjectDescription { get; set; }

Property Value

string

SubjectType

The subject type of a subject reference image.

[JsonPropertyName("subjectType")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public SubjectReferenceType? SubjectType { get; set; }

Property Value

SubjectReferenceType?

Methods

FromJson(string, JsonSerializerOptions?)

Deserializes a JSON string to a SubjectReferenceConfig object.

public static SubjectReferenceConfig? FromJson(string jsonString, JsonSerializerOptions? options = null)

Parameters

jsonString string

The JSON string to deserialize.

options JsonSerializerOptions

Optional JsonSerializerOptions.

Returns

SubjectReferenceConfig

The deserialized SubjectReferenceConfig object, or null if deserialization fails.