다음을 통해 공유


ResourceSkuRestrictions Class

  • java.lang.Object
    • com.azure.resourcemanager.appplatform.models.ResourceSkuRestrictions

Implements

public final class ResourceSkuRestrictions
implements JsonSerializable<ResourceSkuRestrictions>

Restrictions where the SKU cannot be used.

Constructor Summary

Constructor Description
ResourceSkuRestrictions()

Creates an instance of ResourceSkuRestrictions class.

Method Summary

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

Reads an instance of ResourceSkuRestrictions from the JsonReader.

ResourceSkuRestrictionsReasonCode reasonCode()

Get the reasonCode property: Gets the reason for restriction.

ResourceSkuRestrictionInfo restrictionInfo()

Get the restrictionInfo property: Gets the information about the restriction where the SKU cannot be used.

JsonWriter toJson(JsonWriter jsonWriter)
ResourceSkuRestrictionsType type()

Get the type property: Gets the type of restrictions.

void validate()

Validates the instance.

List<String> values()

Get the values property: Gets the value of restrictions.

ResourceSkuRestrictions withReasonCode(ResourceSkuRestrictionsReasonCode reasonCode)

Set the reasonCode property: Gets the reason for restriction.

ResourceSkuRestrictions withRestrictionInfo(ResourceSkuRestrictionInfo restrictionInfo)

Set the restrictionInfo property: Gets the information about the restriction where the SKU cannot be used.

ResourceSkuRestrictions withType(ResourceSkuRestrictionsType type)

Set the type property: Gets the type of restrictions.

ResourceSkuRestrictions withValues(List<String> values)

Set the values property: Gets the value of restrictions.

Methods inherited from java.lang.Object

Constructor Details

ResourceSkuRestrictions

public ResourceSkuRestrictions()

Creates an instance of ResourceSkuRestrictions class.

Method Details

fromJson

public static ResourceSkuRestrictions fromJson(JsonReader jsonReader)

Reads an instance of ResourceSkuRestrictions from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

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

reasonCode

public ResourceSkuRestrictionsReasonCode reasonCode()

Get the reasonCode property: Gets the reason for restriction. Possible values include: 'QuotaId', 'NotAvailableForSubscription'.

Returns:

the reasonCode value.

restrictionInfo

public ResourceSkuRestrictionInfo restrictionInfo()

Get the restrictionInfo property: Gets the information about the restriction where the SKU cannot be used.

Returns:

the restrictionInfo value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

type

public ResourceSkuRestrictionsType type()

Get the type property: Gets the type of restrictions. Possible values include: 'Location', 'Zone'.

Returns:

the type value.

validate

public void validate()

Validates the instance.

values

public List values()

Get the values property: Gets the value of restrictions. If the restriction type is set to location. This would be different locations where the SKU is restricted.

Returns:

the values value.

withReasonCode

public ResourceSkuRestrictions withReasonCode(ResourceSkuRestrictionsReasonCode reasonCode)

Set the reasonCode property: Gets the reason for restriction. Possible values include: 'QuotaId', 'NotAvailableForSubscription'.

Parameters:

reasonCode - the reasonCode value to set.

Returns:

the ResourceSkuRestrictions object itself.

withRestrictionInfo

public ResourceSkuRestrictions withRestrictionInfo(ResourceSkuRestrictionInfo restrictionInfo)

Set the restrictionInfo property: Gets the information about the restriction where the SKU cannot be used.

Parameters:

restrictionInfo - the restrictionInfo value to set.

Returns:

the ResourceSkuRestrictions object itself.

withType

public ResourceSkuRestrictions withType(ResourceSkuRestrictionsType type)

Set the type property: Gets the type of restrictions. Possible values include: 'Location', 'Zone'.

Parameters:

type - the type value to set.

Returns:

the ResourceSkuRestrictions object itself.

withValues

public ResourceSkuRestrictions withValues(List values)

Set the values property: Gets the value of restrictions. If the restriction type is set to location. This would be different locations where the SKU is restricted.

Parameters:

values - the values value to set.

Returns:

the ResourceSkuRestrictions object itself.

Applies to