Partager via


OptionsResource Class

  • java.lang.Object
    • com.azure.resourcemanager.cosmos.models.OptionsResource

Implements

public class OptionsResource
implements JsonSerializable<OptionsResource>

Cosmos DB options resource object.

Constructor Summary

Constructor Description
OptionsResource()

Creates an instance of OptionsResource class.

Method Summary

Modifier and Type Method and Description
AutoscaleSettings autoscaleSettings()

Get the autoscaleSettings property: Specifies the Autoscale settings.

static OptionsResource fromJson(JsonReader jsonReader)

Reads an instance of OptionsResource from the JsonReader.

Integer throughput()

Get the throughput property: Value of the Cosmos DB resource throughput or autoscaleSettings.

JsonWriter toJson(JsonWriter jsonWriter)
void validate()

Validates the instance.

OptionsResource withAutoscaleSettings(AutoscaleSettings autoscaleSettings)

Set the autoscaleSettings property: Specifies the Autoscale settings.

OptionsResource withThroughput(Integer throughput)

Set the throughput property: Value of the Cosmos DB resource throughput or autoscaleSettings.

Methods inherited from java.lang.Object

Constructor Details

OptionsResource

public OptionsResource()

Creates an instance of OptionsResource class.

Method Details

autoscaleSettings

public AutoscaleSettings autoscaleSettings()

Get the autoscaleSettings property: Specifies the Autoscale settings.

Returns:

the autoscaleSettings value.

fromJson

public static OptionsResource fromJson(JsonReader jsonReader)

Reads an instance of OptionsResource from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of OptionsResource 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 OptionsResource.

throughput

public Integer throughput()

Get the throughput property: Value of the Cosmos DB resource throughput or autoscaleSettings. Use the ThroughputSetting resource when retrieving offer details.

Returns:

the throughput value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

validate

public void validate()

Validates the instance.

withAutoscaleSettings

public OptionsResource withAutoscaleSettings(AutoscaleSettings autoscaleSettings)

Set the autoscaleSettings property: Specifies the Autoscale settings.

Parameters:

autoscaleSettings - the autoscaleSettings value to set.

Returns:

the OptionsResource object itself.

withThroughput

public OptionsResource withThroughput(Integer throughput)

Set the throughput property: Value of the Cosmos DB resource throughput or autoscaleSettings. Use the ThroughputSetting resource when retrieving offer details.

Parameters:

throughput - the throughput value to set.

Returns:

the OptionsResource object itself.

Applies to