SavingsPlanModelInner Class

public final class SavingsPlanModelInner
extends ProxyResourceWithTags

Savings plan.

Constructor Summary

Constructor Description
SavingsPlanModelInner()

Creates an instance of SavingsPlanModelInner class.

Method Summary

Modifier and Type Method and Description
AppliedScopeProperties appliedScopeProperties()

Get the appliedScopeProperties property: Properties specific to applied scope type.

AppliedScopeType appliedScopeType()

Get the appliedScopeType property: Type of the Applied Scope.

OffsetDateTime benefitStartTime()

Get the benefitStartTime property: This is the DateTime when the savings plan benefit starts.

String billingAccountId()

Get the billingAccountId property: Fully-qualified identifier of the billing account where the savings plan is applied.

BillingPlan billingPlan()

Get the billingPlan property: Represents the billing plan in ISO 8601 format.

String billingProfileId()

Get the billingProfileId property: Fully-qualified identifier of the billing profile where the savings plan is applied.

String billingScopeId()

Get the billingScopeId property: Subscription that will be charged for purchasing SavingsPlan.

Commitment commitment()

Get the commitment property: Commitment towards the benefit.

String customerId()

Get the customerId property: Fully-qualified identifier of the customer where the savings plan is applied.

String displayName()

Get the displayName property: Display name.

String displayProvisioningState()

Get the displayProvisioningState property: The provisioning state of the savings plan for display, e.g.

OffsetDateTime effectiveDateTime()

Get the effectiveDateTime property: DateTime of the savings plan starting when this version is effective from.

OffsetDateTime expiryDateTime()

Get the expiryDateTime property: This is the date-time when the savings plan will expire.

ExtendedStatusInfo extendedStatusInfo()

Get the extendedStatusInfo property: Extended status information.

static SavingsPlanModelInner fromJson(JsonReader jsonReader)

Reads an instance of SavingsPlanModelInner from the JsonReader.

String id()

Get the id property: Fully qualified resource Id for the resource.

String name()

Get the name property: The name of the resource.

String productCode()

Get the productCode property: Represents UPN.

ProvisioningState provisioningState()

Get the provisioningState property: The provisioning state of the resource during a long-running operation.

OffsetDateTime purchaseDateTime()

Get the purchaseDateTime property: Date time when the savings plan was purchased.

Boolean renew()

Get the renew property: Setting this to true will automatically purchase a new benefit on the expiration date time.

String renewDestination()

Get the renewDestination property: SavingsPlan Id of the SavingsPlan which is purchased because of renew.

RenewProperties renewProperties()

Get the renewProperties property: Properties specific to renew.

String renewSource()

Get the renewSource property: SavingsPlan Id of the SavingsPlan from which this SavingsPlan is renewed.

Sku sku()

Get the sku property: Savings plan SKU.

SystemData systemData()

Get the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.

SavingsPlanTerm term()

Get the term property: Represents the Savings plan term in ISO 8601 format.

JsonWriter toJson(JsonWriter jsonWriter)
String type()

Get the type property: The type of the resource.

String userFriendlyAppliedScopeType()

Get the userFriendlyAppliedScopeType property: The applied scope type of the savings plan for display, e.g.

Utilization utilization()

Get the utilization property: Savings plan utilization.

void validate()

Validates the instance.

SavingsPlanModelInner withAppliedScopeProperties(AppliedScopeProperties appliedScopeProperties)

Set the appliedScopeProperties property: Properties specific to applied scope type.

SavingsPlanModelInner withAppliedScopeType(AppliedScopeType appliedScopeType)

Set the appliedScopeType property: Type of the Applied Scope.

SavingsPlanModelInner withBillingPlan(BillingPlan billingPlan)

Set the billingPlan property: Represents the billing plan in ISO 8601 format.

SavingsPlanModelInner withBillingScopeId(String billingScopeId)

Set the billingScopeId property: Subscription that will be charged for purchasing SavingsPlan.

SavingsPlanModelInner withCommitment(Commitment commitment)

Set the commitment property: Commitment towards the benefit.

SavingsPlanModelInner withDisplayName(String displayName)

Set the displayName property: Display name.

SavingsPlanModelInner withProductCode(String productCode)

Set the productCode property: Represents UPN.

SavingsPlanModelInner withProvisioningState(ProvisioningState provisioningState)

Set the provisioningState property: The provisioning state of the resource during a long-running operation.

SavingsPlanModelInner withRenew(Boolean renew)

Set the renew property: Setting this to true will automatically purchase a new benefit on the expiration date time.

SavingsPlanModelInner withRenewDestination(String renewDestination)

Set the renewDestination property: SavingsPlan Id of the SavingsPlan which is purchased because of renew.

SavingsPlanModelInner withRenewProperties(RenewProperties renewProperties)

Set the renewProperties property: Properties specific to renew.

SavingsPlanModelInner withRenewSource(String renewSource)

Set the renewSource property: SavingsPlan Id of the SavingsPlan from which this SavingsPlan is renewed.

SavingsPlanModelInner withSku(Sku sku)

Set the sku property: Savings plan SKU.

SavingsPlanModelInner withTags(Map<String,String> tags)

Set the tags property: Dictionary of metadata associated with the resource.

SavingsPlanModelInner withTerm(SavingsPlanTerm term)

Set the term property: Represents the Savings plan term in ISO 8601 format.

Methods inherited from ProxyResourceWithTags

Methods inherited from java.lang.Object

Constructor Details

SavingsPlanModelInner

public SavingsPlanModelInner()

Creates an instance of SavingsPlanModelInner class.

Method Details

appliedScopeProperties

public AppliedScopeProperties appliedScopeProperties()

Get the appliedScopeProperties property: Properties specific to applied scope type. Not required if not applicable.

Returns:

the appliedScopeProperties value.

appliedScopeType

public AppliedScopeType appliedScopeType()

Get the appliedScopeType property: Type of the Applied Scope.

Returns:

the appliedScopeType value.

benefitStartTime

public OffsetDateTime benefitStartTime()

Get the benefitStartTime property: This is the DateTime when the savings plan benefit starts.

Returns:

the benefitStartTime value.

billingAccountId

public String billingAccountId()

Get the billingAccountId property: Fully-qualified identifier of the billing account where the savings plan is applied.

Returns:

the billingAccountId value.

billingPlan

public BillingPlan billingPlan()

Get the billingPlan property: Represents the billing plan in ISO 8601 format. Required only for monthly purchases.

Returns:

the billingPlan value.

billingProfileId

public String billingProfileId()

Get the billingProfileId property: Fully-qualified identifier of the billing profile where the savings plan is applied. Present only for Field-led or Customer-led customers.

Returns:

the billingProfileId value.

billingScopeId

public String billingScopeId()

Get the billingScopeId property: Subscription that will be charged for purchasing SavingsPlan.

Returns:

the billingScopeId value.

commitment

public Commitment commitment()

Get the commitment property: Commitment towards the benefit.

Returns:

the commitment value.

customerId

public String customerId()

Get the customerId property: Fully-qualified identifier of the customer where the savings plan is applied. Present only for Partner-led customers.

Returns:

the customerId value.

displayName

public String displayName()

Get the displayName property: Display name.

Returns:

the displayName value.

displayProvisioningState

public String displayProvisioningState()

Get the displayProvisioningState property: The provisioning state of the savings plan for display, e.g. Succeeded.

Returns:

the displayProvisioningState value.

effectiveDateTime

public OffsetDateTime effectiveDateTime()

Get the effectiveDateTime property: DateTime of the savings plan starting when this version is effective from.

Returns:

the effectiveDateTime value.

expiryDateTime

public OffsetDateTime expiryDateTime()

Get the expiryDateTime property: This is the date-time when the savings plan will expire.

Returns:

the expiryDateTime value.

extendedStatusInfo

public ExtendedStatusInfo extendedStatusInfo()

Get the extendedStatusInfo property: Extended status information.

Returns:

the extendedStatusInfo value.

fromJson

public static SavingsPlanModelInner fromJson(JsonReader jsonReader)

Reads an instance of SavingsPlanModelInner from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of SavingsPlanModelInner if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If the deserialized JSON object was missing any required properties.

id

public String id()

Get the id property: Fully qualified resource Id for the resource.

Overrides:

SavingsPlanModelInner.id()

Returns:

the id value.

name

public String name()

Get the name property: The name of the resource.

Overrides:

SavingsPlanModelInner.name()

Returns:

the name value.

productCode

public String productCode()

Get the productCode property: Represents UPN.

Returns:

the productCode value.

provisioningState

public ProvisioningState provisioningState()

Get the provisioningState property: The provisioning state of the resource during a long-running operation.

Returns:

the provisioningState value.

purchaseDateTime

public OffsetDateTime purchaseDateTime()

Get the purchaseDateTime property: Date time when the savings plan was purchased.

Returns:

the purchaseDateTime value.

renew

public Boolean renew()

Get the renew property: Setting this to true will automatically purchase a new benefit on the expiration date time.

Returns:

the renew value.

renewDestination

public String renewDestination()

Get the renewDestination property: SavingsPlan Id of the SavingsPlan which is purchased because of renew.

Returns:

the renewDestination value.

renewProperties

public RenewProperties renewProperties()

Get the renewProperties property: Properties specific to renew.

Returns:

the renewProperties value.

renewSource

public String renewSource()

Get the renewSource property: SavingsPlan Id of the SavingsPlan from which this SavingsPlan is renewed.

Returns:

the renewSource value.

sku

public Sku sku()

Get the sku property: Savings plan SKU.

Returns:

the sku value.

systemData

public SystemData systemData()

Get the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.

Overrides:

SavingsPlanModelInner.systemData()

Returns:

the systemData value.

term

public SavingsPlanTerm term()

Get the term property: Represents the Savings plan term in ISO 8601 format.

Returns:

the term value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Overrides:

SavingsPlanModelInner.toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

type

public String type()

Get the type property: The type of the resource.

Overrides:

SavingsPlanModelInner.type()

Returns:

the type value.

userFriendlyAppliedScopeType

public String userFriendlyAppliedScopeType()

Get the userFriendlyAppliedScopeType property: The applied scope type of the savings plan for display, e.g. Shared.

Returns:

the userFriendlyAppliedScopeType value.

utilization

public Utilization utilization()

Get the utilization property: Savings plan utilization.

Returns:

the utilization value.

validate

public void validate()

Validates the instance.

Overrides:

SavingsPlanModelInner.validate()

withAppliedScopeProperties

public SavingsPlanModelInner withAppliedScopeProperties(AppliedScopeProperties appliedScopeProperties)

Set the appliedScopeProperties property: Properties specific to applied scope type. Not required if not applicable.

Parameters:

appliedScopeProperties - the appliedScopeProperties value to set.

Returns:

the SavingsPlanModelInner object itself.

withAppliedScopeType

public SavingsPlanModelInner withAppliedScopeType(AppliedScopeType appliedScopeType)

Set the appliedScopeType property: Type of the Applied Scope.

Parameters:

appliedScopeType - the appliedScopeType value to set.

Returns:

the SavingsPlanModelInner object itself.

withBillingPlan

public SavingsPlanModelInner withBillingPlan(BillingPlan billingPlan)

Set the billingPlan property: Represents the billing plan in ISO 8601 format. Required only for monthly purchases.

Parameters:

billingPlan - the billingPlan value to set.

Returns:

the SavingsPlanModelInner object itself.

withBillingScopeId

public SavingsPlanModelInner withBillingScopeId(String billingScopeId)

Set the billingScopeId property: Subscription that will be charged for purchasing SavingsPlan.

Parameters:

billingScopeId - the billingScopeId value to set.

Returns:

the SavingsPlanModelInner object itself.

withCommitment

public SavingsPlanModelInner withCommitment(Commitment commitment)

Set the commitment property: Commitment towards the benefit.

Parameters:

commitment - the commitment value to set.

Returns:

the SavingsPlanModelInner object itself.

withDisplayName

public SavingsPlanModelInner withDisplayName(String displayName)

Set the displayName property: Display name.

Parameters:

displayName - the displayName value to set.

Returns:

the SavingsPlanModelInner object itself.

withProductCode

public SavingsPlanModelInner withProductCode(String productCode)

Set the productCode property: Represents UPN.

Parameters:

productCode - the productCode value to set.

Returns:

the SavingsPlanModelInner object itself.

withProvisioningState

public SavingsPlanModelInner withProvisioningState(ProvisioningState provisioningState)

Set the provisioningState property: The provisioning state of the resource during a long-running operation.

Parameters:

provisioningState - the provisioningState value to set.

Returns:

the SavingsPlanModelInner object itself.

withRenew

public SavingsPlanModelInner withRenew(Boolean renew)

Set the renew property: Setting this to true will automatically purchase a new benefit on the expiration date time.

Parameters:

renew - the renew value to set.

Returns:

the SavingsPlanModelInner object itself.

withRenewDestination

public SavingsPlanModelInner withRenewDestination(String renewDestination)

Set the renewDestination property: SavingsPlan Id of the SavingsPlan which is purchased because of renew.

Parameters:

renewDestination - the renewDestination value to set.

Returns:

the SavingsPlanModelInner object itself.

withRenewProperties

public SavingsPlanModelInner withRenewProperties(RenewProperties renewProperties)

Set the renewProperties property: Properties specific to renew.

Parameters:

renewProperties - the renewProperties value to set.

Returns:

the SavingsPlanModelInner object itself.

withRenewSource

public SavingsPlanModelInner withRenewSource(String renewSource)

Set the renewSource property: SavingsPlan Id of the SavingsPlan from which this SavingsPlan is renewed.

Parameters:

renewSource - the renewSource value to set.

Returns:

the SavingsPlanModelInner object itself.

withSku

public SavingsPlanModelInner withSku(Sku sku)

Set the sku property: Savings plan SKU.

Parameters:

sku - the sku value to set.

Returns:

the SavingsPlanModelInner object itself.

withTags

public SavingsPlanModelInner withTags(Map<String,String> tags)

Set the tags property: Dictionary of metadata associated with the resource. It may not be populated for all resource types. Maximum key/value length supported of 256 characters. Keys/value should not empty value nor null. Keys can not contain < > % & \ ? /.

Overrides:

SavingsPlanModelInner.withTags(Map<String,String> tags)

Parameters:

tags

withTerm

public SavingsPlanModelInner withTerm(SavingsPlanTerm term)

Set the term property: Represents the Savings plan term in ISO 8601 format.

Parameters:

term - the term value to set.

Returns:

the SavingsPlanModelInner object itself.

Applies to