Partager via


Capability Class

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

Implements

public final class Capability
implements JsonSerializable<Capability>

Cosmos DB capability object.

Constructor Summary

Constructor Description
Capability()

Creates an instance of Capability class.

Method Summary

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

Reads an instance of Capability from the JsonReader.

String name()

Get the name property: Name of the Cosmos DB capability.

JsonWriter toJson(JsonWriter jsonWriter)
void validate()

Validates the instance.

Capability withName(String name)

Set the name property: Name of the Cosmos DB capability.

Methods inherited from java.lang.Object

Constructor Details

Capability

public Capability()

Creates an instance of Capability class.

Method Details

fromJson

public static Capability fromJson(JsonReader jsonReader)

Reads an instance of Capability from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

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

name

public String name()

Get the name property: Name of the Cosmos DB capability. For example, "name": "EnableCassandra". Current values also include "EnableTable" and "EnableGremlin".

Returns:

the name value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

validate

public void validate()

Validates the instance.

withName

public Capability withName(String name)

Set the name property: Name of the Cosmos DB capability. For example, "name": "EnableCassandra". Current values also include "EnableTable" and "EnableGremlin".

Parameters:

name - the name value to set.

Returns:

the Capability object itself.

Applies to