Class Subscription


public class Subscription
extends Contract
The subscription resource represents the life cycle of a subscription and includes properties that define the states throughout the subscription life cycle
  • Constructor Details

    • Subscription

      public Subscription()
      Initializes a new instance of the subscription class.
  • Method Details

    • getActions

      public Iterable<String> getActions()
      Gets the available actions for the subscription.
      Returns:
      The available actions for the subscription.
    • getCreationDate

      public org.joda.time.DateTime getCreationDate()
      Gets the date and time when the subscription was created.
      Returns:
      The date and time when the subscription was created.
    • setCreationDate

      public void setCreationDate​(org.joda.time.DateTime value)
      Sets the date and time when the subscription was created.
      Parameters:
      value - The date and time when the subscription was created.
    • getFriendlyName

      public String getFriendlyName()
      Gets the friendly name for the subscription.
      Returns:
      The friendly name for the subscription.
    • setFriendlyName

      public void setFriendlyName​(String value)
      Sets the friendly name for the subscription.
      Parameters:
      value - The friendly name for the subscription.
    • getHasPurchasableAddOns

      public Boolean getHasPurchasableAddOns()
      Gets a flag indicating whether or not the subscription has purchasable addons.
      Returns:
      A flag indicating whether or not the subscription has purchasable addons.
    • getId

      public String getId()
      Gets the subscription identifier.
      Returns:
      The identifier for the subscription.
    • setId

      public void setId​(String value)
      Sets the identifier for the subscription.
      Parameters:
      value - The identifier for the subscription.
    • getIsMicrosoftProduct

      public boolean getIsMicrosoftProduct()
      Gets a flag indicating whether gets or sets the value indicating that the subscription is a Microsoft product.
      Returns:
      A flag indicating whether gets or sets the value indicating that the subscription is a Microsoft product.
    • setIsMicrosoftProduct

      public void setIsMicrosoftProduct​(boolean value)
      Sets a flag indicating whether gets or sets the value indicating that the subscription is a Microsoft product.
      Parameters:
      value - A flag indicating whether gets or sets the value indicating that the subscription is a Microsoft product.
    • getIsTrial

      public boolean getIsTrial()
      Gets a flag indicating whether or not the subscription is a trial.
      Returns:
      A flag indicating whether or not the subscription is a trial.
    • getOfferId

      public String getOfferId()
      Gets the offer identifier that created the subscription.
      Returns:
      The offer identifier that created the subscription.
    • setOfferId

      public void setOfferId​(String value)
      Sets the offer identifier that created the subscription.
      Parameters:
      value - The offer identifier that created the subscription.
    • getOfferName

      public String getOfferName()
      Get the name of the offer that created the subscription.
      Returns:
      The name of the offer that created the subscription.
    • setOfferName

      public void setOfferName​(String value)
      Sets the name of the offer that created the subscription.
      Parameters:
      value - The name of the offer that created the subscription.
    • getParentSubscriptionId

      public String getParentSubscriptionId()
      Gets the parent subscription identifier for the subscription.
      Returns:
      The parent subscription identifier for the subscription.
    • setParentSubscriptionId

      public void setParentSubscriptionId​(String value)
      Sets the parent subscription identifier for the subscription.
      Parameters:
      value - The parent subscription identifier for the subscription.
    • getPublisherName

      public String getPublisherName()
      Gets the name of the publisher.
      Returns:
      The name of the publisher.
    • setPublisherName

      public void setPublisherName​(String value)
      Sets the name of the publisher.
      Parameters:
      value - The name of the publisher.
    • getEntitlementId

      public String getEntitlementId()
      Gets the entitlement identifier for the subscription.
      Returns:
      The entitlement identifier for the subscription.
    • setEntitlementId

      public void setEntitlementId​(String value)
      Sets the entitlement identifier for the subscription.
      Parameters:
      value - The entitlement identifier for the subscription.
    • getBillingCycle

      public BillingCycleType getBillingCycle()
      Gets the billing cycle type for the subscription.
      Returns:
      The billing cycle type
    • setBillingCycle

      public void setBillingCycle​(BillingCycleType billingCycle)
      Sets the billing cycle type for the subscription
      Parameters:
      billingCycle - The billing cycle type for the subscription
    • getQuantity

      public int getQuantity()
      Gets the quantity for the subscription. In the case of seat based billing, this value is the seat count.
      Returns:
      The quantity for the subscription.
    • setQuantity

      public void setQuantity​(int value)
      Sets the quantity for the subscription. In the case of seat based billing, this value is the seat count.
      Parameters:
      value - The quantity for the subscription.
    • getTermDuration

      public String getTermDuration()
      Gets the ISO 8601 representation of the term's duration. The current supported values are P1M (1 month), P1Y (1 year) and P3Y (3 years).
      Returns:
      The ISO 8601 representation of the term's duration.
    • setTermDuration

      public void setTermDuration​(String value)
      Sets the ISO 8601 representation of the term's duration. The current supported values are P1M (1 month), P1Y (1 year) and P3Y (3 years).
      Parameters:
      value - The ISO 8601 representation of the term's duration.
    • getUnitType

      public String getUnitType()
      Gets the units defining the quantity for the subscription.
      Returns:
      The units defining the quantity for the subscription.
    • setUnitType

      public void setUnitType​(String value)
      Sets the units defining the quantity for the subscription.
      Parameters:
      value - The units defining the quantity for the subscription.
    • getEffectiveStartDate

      public org.joda.time.DateTime getEffectiveStartDate()
    • setEffectiveStartDate

      public void setEffectiveStartDate​(org.joda.time.DateTime value)
    • getCommitmentEndDate

      public org.joda.time.DateTime getCommitmentEndDate()
    • setCommitmentEndDate

      public void setCommitmentEndDate​(org.joda.time.DateTime value)
    • getStatus

      public SubscriptionStatus getStatus()
    • setStatus

      public void setStatus​(SubscriptionStatus value)
    • getAutoRenewEnabled

      public boolean getAutoRenewEnabled()
    • setAutoRenewEnabled

      public void setAutoRenewEnabled​(boolean value)
    • getBillingType

      public BillingType getBillingType()
    • setBillingType

      public void setBillingType​(BillingType value)
    • getPartnerId

      public String getPartnerId()
    • setPartnerId

      public void setPartnerId​(String value)
    • getContractType

      public ContractType getContractType()
      Gets the type of contract
      Specified by:
      getContractType in class Contract
      Returns:
      The contract type.
    • setContractType

      public void setContractType​(ContractType type)
    • getLinks

      public SubscriptionLinks getLinks()
    • setLinks

      public void setLinks​(SubscriptionLinks value)
    • getSuspensionReasons

      public Iterable<String> getSuspensionReasons()
    • setSuspensionReasons

      public void setSuspensionReasons​(Iterable<String> value)
    • getRefundOptions

      public Iterable<RefundOption> getRefundOptions()
      Gets the refund options for this subscription if applicable.
      Returns:
      The refund options for this subscription if applicable.
    • setRefundOptions

      public void setRefundOptions​(Iterable<RefundOption> value)
      Sets the refund options for this subscription if applicable.
      Parameters:
      value - The refund options for this subscription if applicable.
    • getRenewalTermDuration

      public String getRenewalTermDuration()
      Gets the renewal term duration.
      Returns:
      The renewal term duration.
    • setRenewalTermDuration

      public void setRenewalTermDuration​(String value)
      Sets the renewal term duration.
      Parameters:
      value - The renewal term duration.