Partilhar via


DatabaseIdentity Class

  • java.lang.Object
    • com.azure.resourcemanager.sql.models.DatabaseIdentity

Implements

public final class DatabaseIdentity
implements JsonSerializable<DatabaseIdentity>

Azure Active Directory identity configuration for a resource.

Constructor Summary

Constructor Description
DatabaseIdentity()

Creates an instance of DatabaseIdentity class.

Method Summary

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

Reads an instance of DatabaseIdentity from the JsonReader.

UUID tenantId()

Get the tenantId property: The Azure Active Directory tenant id.

JsonWriter toJson(JsonWriter jsonWriter)
DatabaseIdentityType type()

Get the type property: The identity type.

Map<String,DatabaseUserIdentity> userAssignedIdentities()

Get the userAssignedIdentities property: The resource ids of the user assigned identities to use.

void validate()

Validates the instance.

DatabaseIdentity withType(DatabaseIdentityType type)

Set the type property: The identity type.

DatabaseIdentity withUserAssignedIdentities(Map<String,DatabaseUserIdentity> userAssignedIdentities)

Set the userAssignedIdentities property: The resource ids of the user assigned identities to use.

Methods inherited from java.lang.Object

Constructor Details

DatabaseIdentity

public DatabaseIdentity()

Creates an instance of DatabaseIdentity class.

Method Details

fromJson

public static DatabaseIdentity fromJson(JsonReader jsonReader)

Reads an instance of DatabaseIdentity from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

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

tenantId

public UUID tenantId()

Get the tenantId property: The Azure Active Directory tenant id.

Returns:

the tenantId value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

type

public DatabaseIdentityType type()

Get the type property: The identity type.

Returns:

the type value.

userAssignedIdentities

public Map userAssignedIdentities()

Get the userAssignedIdentities property: The resource ids of the user assigned identities to use.

Returns:

the userAssignedIdentities value.

validate

public void validate()

Validates the instance.

withType

public DatabaseIdentity withType(DatabaseIdentityType type)

Set the type property: The identity type.

Parameters:

type - the type value to set.

Returns:

the DatabaseIdentity object itself.

withUserAssignedIdentities

public DatabaseIdentity withUserAssignedIdentities(Map userAssignedIdentities)

Set the userAssignedIdentities property: The resource ids of the user assigned identities to use.

Parameters:

userAssignedIdentities - the userAssignedIdentities value to set.

Returns:

the DatabaseIdentity object itself.

Applies to