VersionSelectionRule Class

  • java.lang.Object
    • com.azure.ai.agents.models.VersionSelectionRule

Implements

public class VersionSelectionRule
implements JsonSerializable<VersionSelectionRule>

The VersionSelectionRule model.

Constructor Summary

Constructor Description
VersionSelectionRule()

Creates an instance of VersionSelectionRule class.

Method Summary

Modifier and Type Method and Description
static VersionSelectionRule fromJson(JsonReader jsonReader)

Reads an instance of VersionSelectionRule from the JsonReader.

String getAgentVersion()

Get the agentVersion property: The agent version to route traffic to.

VersionSelectorType getType()

Get the type property: The type property.

VersionSelectionRule setAgentVersion(String agentVersion)

Set the agentVersion property: The agent version to route traffic to.

JsonWriter toJson(JsonWriter jsonWriter)

Methods inherited from java.lang.Object

Constructor Details

VersionSelectionRule

public VersionSelectionRule()

Creates an instance of VersionSelectionRule class.

Method Details

fromJson

public static VersionSelectionRule fromJson(JsonReader jsonReader)

Reads an instance of VersionSelectionRule from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of VersionSelectionRule if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If an error occurs while reading the VersionSelectionRule.

getAgentVersion

public String getAgentVersion()

Get the agentVersion property: The agent version to route traffic to.

Returns:

the agentVersion value.

getType

public VersionSelectorType getType()

Get the type property: The type property.

Returns:

the type value.

setAgentVersion

public VersionSelectionRule setAgentVersion(String agentVersion)

Set the agentVersion property: The agent version to route traffic to.

Required when create the resource.

Parameters:

agentVersion - the agentVersion value to set.

Returns:

the VersionSelectionRule object itself.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

Applies to