public interface Entitlement extends Entity
EntitlementApi
It contains all the catalog information and current state that answers the entitlement question.
The users of that API will control all the entitlement behavior when making changes such as the effectiveDate, catalog info,...
By default the system will use system wide policies to control the billing aspect, but specific APIs also allow to override those.
EntitlementApi| Modifier and Type | Interface and Description |
|---|---|
static class |
Entitlement.EntitlementActionPolicy
Used to control the effective date that should be used on Plan change or on cancellation.
|
static class |
Entitlement.EntitlementSourceType
Possible
Entitlement source types. |
static class |
Entitlement.EntitlementState
Possible states of an
Entitlement |
| Modifier and Type | Method and Description |
|---|---|
Entitlement |
cancelEntitlementWithDate(org.joda.time.LocalDate effectiveDate,
boolean overrideBillingEffectiveDate,
CallContext context)
Cancels the
Entitlement at the specified date. |
Entitlement |
cancelEntitlementWithDateOverrideBillingPolicy(org.joda.time.LocalDate effectiveDate,
BillingActionPolicy billingPolicy,
CallContext context)
Cancels the
Entitlement at the specified date
After this operation, the existing object becomes stale. |
Entitlement |
cancelEntitlementWithPolicy(Entitlement.EntitlementActionPolicy policy,
CallContext context)
Cancel the
Entitlement with a policy. |
Entitlement |
cancelEntitlementWithPolicyOverrideBillingPolicy(Entitlement.EntitlementActionPolicy policy,
BillingActionPolicy billingPolicy,
CallContext context)
Cancels the
Entitlement at the specified date and overrides the default billing policy. |
Entitlement |
changePlan(String productName,
BillingPeriod billingPeriod,
String priceList,
List<PlanPhasePriceOverride> overrides,
CallContext context)
Change
Entitlement plan using default policy. |
Entitlement |
changePlanOverrideBillingPolicy(String productName,
BillingPeriod billingPeriod,
String priceList,
List<PlanPhasePriceOverride> overrides,
org.joda.time.LocalDate effectiveDate,
BillingActionPolicy billingPolicy,
CallContext context)
Change
Entitlement plan at the specified date and overrides the billing policy. |
Entitlement |
changePlanWithDate(String productName,
BillingPeriod billingPeriod,
String priceList,
List<PlanPhasePriceOverride> overrides,
org.joda.time.LocalDate effectiveDate,
CallContext context)
Change
Entitlement plan at the specified date. |
UUID |
getAccountId() |
UUID |
getBaseEntitlementId() |
UUID |
getBundleId() |
org.joda.time.LocalDate |
getEffectiveEndDate() |
org.joda.time.LocalDate |
getEffectiveStartDate() |
String |
getExternalKey() |
PlanPhase |
getLastActivePhase() |
Plan |
getLastActivePlan() |
PriceList |
getLastActivePriceList() |
Product |
getLastActiveProduct() |
ProductCategory |
getLastActiveProductCategory() |
Entitlement.EntitlementSourceType |
getSourceType() |
Entitlement.EntitlementState |
getState() |
void |
uncancelEntitlement(CallContext context)
Removes a pending future cancellation on an entitlement.
|
getCreatedDate, getId, getUpdatedDateUUID getBaseEntitlementId()
UUID getBundleId()
UUID getAccountId()
String getExternalKey()
Entitlement.EntitlementState getState()
Entitlement.EntitlementSourceType getSourceType()
org.joda.time.LocalDate getEffectiveStartDate()
org.joda.time.LocalDate getEffectiveEndDate()
Product getLastActiveProduct()
Product prior to cancellationPlan getLastActivePlan()
Plan prior to cancellationPlanPhase getLastActivePhase()
Phase prior to cancellationPriceList getLastActivePriceList()
ProductCategory getLastActiveProductCategory()
Entitlement cancelEntitlementWithDate(org.joda.time.LocalDate effectiveDate, boolean overrideBillingEffectiveDate, CallContext context) throws EntitlementApiException
Entitlement at the specified date.
After this operation, the existing object becomes stale.
The date is interpreted by the system to be in the timezone specified at the AccounteffectiveDate - the date at which the entitlement should be cancelledoverrideBillingEffectiveDate - use effectiveDate for billing cancellation date as wellcontext - the contextEntitlement after the cancellation was performedEntitlementApiException - if cancellation failedEntitlement cancelEntitlementWithPolicy(Entitlement.EntitlementActionPolicy policy, CallContext context) throws EntitlementApiException
Entitlement with a policy.
After this operation, the existing object becomes stale.policy - the policy that is used by the system to calculate the cancellation datecontext - the contextEntitlement after the cancellation was performedEntitlementApiException - if cancellation failedEntitlement cancelEntitlementWithDateOverrideBillingPolicy(org.joda.time.LocalDate effectiveDate, BillingActionPolicy billingPolicy, CallContext context) throws EntitlementApiException
Entitlement at the specified date
After this operation, the existing object becomes stale.
The date is interpreted by the system to be in the timezone specified at the AccounteffectiveDate - the date at which the entitlement should be cancelledbillingPolicy - the billingPolicycontext - the contextEntitlement after the cancellation was performedEntitlementApiException - if cancellation failedEntitlement cancelEntitlementWithPolicyOverrideBillingPolicy(Entitlement.EntitlementActionPolicy policy, BillingActionPolicy billingPolicy, CallContext context) throws EntitlementApiException
Entitlement at the specified date and overrides the default billing policy.
After this operation, the existing object becomes stale.policy - the policy that is used by the system to calculate the cancellation datebillingPolicy - the override billing policycontext - the contextEntitlement after the cancellation was performedEntitlementApiException - if cancellation failedvoid uncancelEntitlement(CallContext context) throws EntitlementApiException
context - the contextEntitlementApiExceptionEntitlement changePlan(String productName, BillingPeriod billingPeriod, String priceList, List<PlanPhasePriceOverride> overrides, CallContext context) throws EntitlementApiException
Entitlement plan using default policy.
After this operation, the existing object becomes stale.
The date is interpreted by the system to be in the timezone specified at the AccountproductName - the new product namebillingPeriod - the new billing periodpriceList - the new priceListoverrides - the price override for each phase and for a specific currencycontext - the contextEntitlement after the change was performedEntitlementApiException - if change failedEntitlement changePlanWithDate(String productName, BillingPeriod billingPeriod, String priceList, List<PlanPhasePriceOverride> overrides, org.joda.time.LocalDate effectiveDate, CallContext context) throws EntitlementApiException
Entitlement plan at the specified date.
After this operation, the existing object becomes stale.
The date is interpreted by the system to be in the timezone specified at the AccountproductName - the new product namebillingPeriod - the new billing periodpriceList - the new priceListoverrides - the price override for each phase and for a specific currencyeffectiveDate - the date at which the entitlement should be changedcontext - the contextEntitlement after the change was performedEntitlementApiException - if change failedEntitlement changePlanOverrideBillingPolicy(String productName, BillingPeriod billingPeriod, String priceList, List<PlanPhasePriceOverride> overrides, org.joda.time.LocalDate effectiveDate, BillingActionPolicy billingPolicy, CallContext context) throws EntitlementApiException
Entitlement plan at the specified date and overrides the billing policy.
After this operation, the existing object becomes stale.
The date is interpreted by the system to be in the timezone specified at the AccountproductName - the new product namebillingPeriod - the new billing periodpriceList - the new priceListoverrides - the price override for each phase and for a specific currencyeffectiveDate - the date at which the entitlement should be changedbillingPolicy - the override billing policycontext - the contextEntitlement after the change was performedEntitlementApiException - if change failedCopyright © 2010-2015. All Rights Reserved.