ServicePrincipal Class

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

Implements

public final class ServicePrincipal
implements JsonSerializable<ServicePrincipal>

The managed instance's service principal configuration for a resource.

Constructor Summary

Constructor Description
ServicePrincipal()

Creates an instance of ServicePrincipal class.

Method Summary

Modifier and Type Method and Description
String clientId()

Get the clientId property: The Azure Active Directory application client id.

static ServicePrincipal fromJson(JsonReader jsonReader)

Reads an instance of ServicePrincipal from the JsonReader.

String principalId()

Get the principalId property: The Azure Active Directory application object id.

String tenantId()

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

JsonWriter toJson(JsonWriter jsonWriter)
ServicePrincipalType type()

Get the type property: Service principal type.

void validate()

Validates the instance.

ServicePrincipal withType(ServicePrincipalType type)

Set the type property: Service principal type.

Methods inherited from java.lang.Object

Constructor Details

ServicePrincipal

public ServicePrincipal()

Creates an instance of ServicePrincipal class.

Method Details

clientId

public String clientId()

Get the clientId property: The Azure Active Directory application client id.

Returns:

the clientId value.

fromJson

public static ServicePrincipal fromJson(JsonReader jsonReader)

Reads an instance of ServicePrincipal from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

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

principalId

public String principalId()

Get the principalId property: The Azure Active Directory application object id.

Returns:

the principalId value.

tenantId

public String 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 ServicePrincipalType type()

Get the type property: Service principal type.

Returns:

the type value.

validate

public void validate()

Validates the instance.

withType

public ServicePrincipal withType(ServicePrincipalType type)

Set the type property: Service principal type.

Parameters:

type - the type value to set.

Returns:

the ServicePrincipal object itself.

Applies to