Class BenefitRecommendationProperties

java.lang.Object
com.azure.resourcemanager.costmanagement.models.BenefitRecommendationProperties
Direct Known Subclasses:
SharedScopeBenefitRecommendationProperties, SingleScopeBenefitRecommendationProperties

public class BenefitRecommendationProperties extends Object
The properties of the benefit recommendations.
  • Constructor Details

    • BenefitRecommendationProperties

      public BenefitRecommendationProperties()
      Creates an instance of BenefitRecommendationProperties class.
  • Method Details

    • firstConsumptionDate

      public OffsetDateTime firstConsumptionDate()
      Get the firstConsumptionDate property: The first usage date used for looking back for computing the recommendations.
      Returns:
      the firstConsumptionDate value.
    • lastConsumptionDate

      public OffsetDateTime lastConsumptionDate()
      Get the lastConsumptionDate property: The last usage date used for looking back for computing the recommendations.
      Returns:
      the lastConsumptionDate value.
    • lookBackPeriod

      public LookBackPeriod lookBackPeriod()
      Get the lookBackPeriod property: The number of days of usage evaluated for computing the recommendations.
      Returns:
      the lookBackPeriod value.
    • withLookBackPeriod

      public BenefitRecommendationProperties withLookBackPeriod(LookBackPeriod lookBackPeriod)
      Set the lookBackPeriod property: The number of days of usage evaluated for computing the recommendations.
      Parameters:
      lookBackPeriod - the lookBackPeriod value to set.
      Returns:
      the BenefitRecommendationProperties object itself.
    • totalHours

      public Integer totalHours()
      Get the totalHours property: The total hours for which the cost is covered. Its equal to number of records in a property 'properties/usage/charges'.
      Returns:
      the totalHours value.
    • usage

      Get the usage property: On-demand charges between firstConsumptionDate and lastConsumptionDate that were used for computing benefit recommendations.
      Returns:
      the usage value.
    • withUsage

      Set the usage property: On-demand charges between firstConsumptionDate and lastConsumptionDate that were used for computing benefit recommendations.
      Parameters:
      usage - the usage value to set.
      Returns:
      the BenefitRecommendationProperties object itself.
    • armSkuName

      public String armSkuName()
      Get the armSkuName property: ARM SKU name. 'Compute_Savings_Plan' for SavingsPlan.
      Returns:
      the armSkuName value.
    • term

      public Term term()
      Get the term property: Term period of the benefit. For example, P1Y or P3Y.
      Returns:
      the term value.
    • withTerm

      public BenefitRecommendationProperties withTerm(Term term)
      Set the term property: Term period of the benefit. For example, P1Y or P3Y.
      Parameters:
      term - the term value to set.
      Returns:
      the BenefitRecommendationProperties object itself.
    • commitmentGranularity

      public Grain commitmentGranularity()
      Get the commitmentGranularity property: Grain of the proposed commitment amount. Supported values: 'Hourly'.
      Returns:
      the commitmentGranularity value.
    • withCommitmentGranularity

      public BenefitRecommendationProperties withCommitmentGranularity(Grain commitmentGranularity)
      Set the commitmentGranularity property: Grain of the proposed commitment amount. Supported values: 'Hourly'.
      Parameters:
      commitmentGranularity - the commitmentGranularity value to set.
      Returns:
      the BenefitRecommendationProperties object itself.
    • currencyCode

      public String currencyCode()
      Get the currencyCode property: An ISO 4217 currency code identifier for the costs and savings amounts.
      Returns:
      the currencyCode value.
    • costWithoutBenefit

      public BigDecimal costWithoutBenefit()
      Get the costWithoutBenefit property: The current cost without benefit, corresponds to 'totalHours' in the look-back period.
      Returns:
      the costWithoutBenefit value.
    • recommendationDetails

      public AllSavingsBenefitDetails recommendationDetails()
      Get the recommendationDetails property: The details of the proposed recommendation.
      Returns:
      the recommendationDetails value.
    • withRecommendationDetails

      public BenefitRecommendationProperties withRecommendationDetails(AllSavingsBenefitDetails recommendationDetails)
      Set the recommendationDetails property: The details of the proposed recommendation.
      Parameters:
      recommendationDetails - the recommendationDetails value to set.
      Returns:
      the BenefitRecommendationProperties object itself.
    • allRecommendationDetails

      public AllSavingsList allRecommendationDetails()
      Get the allRecommendationDetails property: The list of all benefit recommendations with the recommendation details.
      Returns:
      the allRecommendationDetails value.
    • validate

      public void validate()
      Validates the instance.
      Throws:
      IllegalArgumentException - thrown if the instance is not valid.