Class Subscription
java.lang.Object
com.microsoft.store.partnercenter.models.ResourceBase
com.microsoft.store.partnercenter.models.Contract
com.microsoft.store.partnercenter.models.subscriptions.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 Summary
Constructors Constructor Description Subscription()Initializes a new instance of the subscription class. -
Method Summary
Modifier and Type Method Description Iterable<String>getActions()Gets the available actions for the subscription.booleangetAutoRenewEnabled()BillingCycleTypegetBillingCycle()Gets the billing cycle type for the subscription.BillingTypegetBillingType()org.joda.time.DateTimegetCommitmentEndDate()ContractTypegetContractType()Gets the type of contractorg.joda.time.DateTimegetCreationDate()Gets the date and time when the subscription was created.org.joda.time.DateTimegetEffectiveStartDate()StringgetEntitlementId()Gets the entitlement identifier for the subscription.StringgetFriendlyName()Gets the friendly name for the subscription.BooleangetHasPurchasableAddOns()Gets a flag indicating whether or not the subscription has purchasable addons.StringgetId()Gets the subscription identifier.booleangetIsMicrosoftProduct()Gets a flag indicating whether gets or sets the value indicating that the subscription is a Microsoft product.booleangetIsTrial()Gets a flag indicating whether or not the subscription is a trial.SubscriptionLinksgetLinks()StringgetOfferId()Gets the offer identifier that created the subscription.StringgetOfferName()Get the name of the offer that created the subscription.StringgetParentSubscriptionId()Gets the parent subscription identifier for the subscription.StringgetPartnerId()StringgetPublisherName()Gets the name of the publisher.intgetQuantity()Gets the quantity for the subscription.Iterable<RefundOption>getRefundOptions()Gets the refund options for this subscription if applicable.StringgetRenewalTermDuration()Gets the renewal term duration.SubscriptionStatusgetStatus()Iterable<String>getSuspensionReasons()StringgetTermDuration()Gets the ISO 8601 representation of the term's duration.StringgetUnitType()Gets the units defining the quantity for the subscription.voidsetAutoRenewEnabled(boolean value)voidsetBillingCycle(BillingCycleType billingCycle)Sets the billing cycle type for the subscriptionvoidsetBillingType(BillingType value)voidsetCommitmentEndDate(org.joda.time.DateTime value)voidsetContractType(ContractType type)voidsetCreationDate(org.joda.time.DateTime value)Sets the date and time when the subscription was created.voidsetEffectiveStartDate(org.joda.time.DateTime value)voidsetEntitlementId(String value)Sets the entitlement identifier for the subscription.voidsetFriendlyName(String value)Sets the friendly name for the subscription.voidsetId(String value)Sets the identifier for the subscription.voidsetIsMicrosoftProduct(boolean value)Sets a flag indicating whether gets or sets the value indicating that the subscription is a Microsoft product.voidsetLinks(SubscriptionLinks value)voidsetOfferId(String value)Sets the offer identifier that created the subscription.voidsetOfferName(String value)Sets the name of the offer that created the subscription.voidsetParentSubscriptionId(String value)Sets the parent subscription identifier for the subscription.voidsetPartnerId(String value)voidsetPublisherName(String value)Sets the name of the publisher.voidsetQuantity(int value)Sets the quantity for the subscription.voidsetRefundOptions(Iterable<RefundOption> value)Sets the refund options for this subscription if applicable.voidsetRenewalTermDuration(String value)Sets the renewal term duration.voidsetStatus(SubscriptionStatus value)voidsetSuspensionReasons(Iterable<String> value)voidsetTermDuration(String value)Sets the ISO 8601 representation of the term's duration.voidsetUnitType(String value)Sets the units defining the quantity for the subscription.Methods inherited from class com.microsoft.store.partnercenter.models.Contract
getOrderId, setOrderId
-
Constructor Details
-
Subscription
public Subscription()Initializes a new instance of the subscription class.
-
-
Method Details
-
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
Gets the friendly name for the subscription.- Returns:
- The friendly name for the subscription.
-
setFriendlyName
Sets the friendly name for the subscription.- Parameters:
value- The friendly name for the subscription.
-
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
Gets the subscription identifier.- Returns:
- The identifier for the subscription.
-
setId
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
Gets the offer identifier that created the subscription.- Returns:
- The offer identifier that created the subscription.
-
setOfferId
Sets the offer identifier that created the subscription.- Parameters:
value- The offer identifier that created the subscription.
-
getOfferName
Get the name of the offer that created the subscription.- Returns:
- The name of the offer that created the subscription.
-
setOfferName
Sets the name of the offer that created the subscription.- Parameters:
value- The name of the offer that created the subscription.
-
getParentSubscriptionId
Gets the parent subscription identifier for the subscription.- Returns:
- The parent subscription identifier for the subscription.
-
setParentSubscriptionId
Sets the parent subscription identifier for the subscription.- Parameters:
value- The parent subscription identifier for the subscription.
-
getPublisherName
Gets the name of the publisher.- Returns:
- The name of the publisher.
-
setPublisherName
Sets the name of the publisher.- Parameters:
value- The name of the publisher.
-
getEntitlementId
Gets the entitlement identifier for the subscription.- Returns:
- The entitlement identifier for the subscription.
-
setEntitlementId
Sets the entitlement identifier for the subscription.- Parameters:
value- The entitlement identifier for the subscription.
-
getBillingCycle
Gets the billing cycle type for the subscription.- Returns:
- The billing cycle type
-
setBillingCycle
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
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
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
Gets the units defining the quantity for the subscription.- Returns:
- The units defining the quantity for the subscription.
-
setUnitType
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
-
setStatus
-
getAutoRenewEnabled
public boolean getAutoRenewEnabled() -
setAutoRenewEnabled
public void setAutoRenewEnabled(boolean value) -
getBillingType
-
setBillingType
-
getPartnerId
-
setPartnerId
-
getContractType
Gets the type of contract- Specified by:
getContractTypein classContract- Returns:
- The contract type.
-
setContractType
-
getLinks
-
setLinks
-
getSuspensionReasons
-
setSuspensionReasons
-
getRefundOptions
Gets the refund options for this subscription if applicable.- Returns:
- The refund options for this subscription if applicable.
-
setRefundOptions
Sets the refund options for this subscription if applicable.- Parameters:
value- The refund options for this subscription if applicable.
-
getRenewalTermDuration
Gets the renewal term duration.- Returns:
- The renewal term duration.
-
setRenewalTermDuration
Sets the renewal term duration.- Parameters:
value- The renewal term duration.
-