Package com.stripe.param
Class SubscriptionScheduleAmendParams.Amendment.Builder
java.lang.Object
com.stripe.param.SubscriptionScheduleAmendParams.Amendment.Builder
- Enclosing class:
- SubscriptionScheduleAmendParams.Amendment
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionAdd all elements to `discountActions` list.Add all elements to `itemActions` list.Add all elements to `metadataActions` list.Add an element to `discountActions` list.Add an element to `itemActions` list.Add an element to `metadataActions` list.build()
Finalize and obtain parameter instance from this builder.putAllExtraParam
(Map<String, Object> map) Add all map key/value pairs to `extraParams` map.putExtraParam
(String key, Object value) Add a key/value pair to `extraParams` map.Details to identify the end of the time range modified by the proposed change.Required. Details to identify the earliest timestamp where the proposed change should take effect.setBillingCycleAnchor
(SubscriptionScheduleAmendParams.Amendment.BillingCycleAnchor billingCycleAnchor) For point-in-time amendments (having noamendment_end
), this attribute lets you set or remove whether the subscription's billing cycle anchor is reset at theamendment_start
timestamp.For time-span based amendments (having bothamendment_start
andamendment_end
), the only value valid isautomatic
, which removes any previously configured billing cycle anchor resets scheduled to occur during the window of time spanned by the amendment.setProrationBehavior
(SubscriptionScheduleAmendParams.Amendment.ProrationBehavior prorationBehavior) Changes to how Stripe handles prorations during the amendment time span.setSetPauseCollection
(SubscriptionScheduleAmendParams.Amendment.SetPauseCollection setPauseCollection) Defines how to pause collection for the underlying subscription throughout the duration of the amendment.Ends the subscription schedule early as dictated by either the accompanying amendment's start or end.Settings related to subscription trials.
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
build
Finalize and obtain parameter instance from this builder. -
setAmendmentEnd
public SubscriptionScheduleAmendParams.Amendment.Builder setAmendmentEnd(SubscriptionScheduleAmendParams.Amendment.AmendmentEnd amendmentEnd) Details to identify the end of the time range modified by the proposed change. If not supplied, the amendment is considered a point-in-time operation that only affects the exact timestamp atamendment_start
, and a restricted set of attributes is supported on the amendment. -
setAmendmentStart
public SubscriptionScheduleAmendParams.Amendment.Builder setAmendmentStart(SubscriptionScheduleAmendParams.Amendment.AmendmentStart amendmentStart) Required. Details to identify the earliest timestamp where the proposed change should take effect. -
setBillingCycleAnchor
public SubscriptionScheduleAmendParams.Amendment.Builder setBillingCycleAnchor(SubscriptionScheduleAmendParams.Amendment.BillingCycleAnchor billingCycleAnchor) For point-in-time amendments (having noamendment_end
), this attribute lets you set or remove whether the subscription's billing cycle anchor is reset at theamendment_start
timestamp.For time-span based amendments (having bothamendment_start
andamendment_end
), the only value valid isautomatic
, which removes any previously configured billing cycle anchor resets scheduled to occur during the window of time spanned by the amendment. -
addDiscountAction
public SubscriptionScheduleAmendParams.Amendment.Builder addDiscountAction(SubscriptionScheduleAmendParams.Amendment.DiscountAction element) Add an element to `discountActions` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. SeeSubscriptionScheduleAmendParams.Amendment.discountActions
for the field documentation. -
addAllDiscountAction
public SubscriptionScheduleAmendParams.Amendment.Builder addAllDiscountAction(List<SubscriptionScheduleAmendParams.Amendment.DiscountAction> elements) Add all elements to `discountActions` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. SeeSubscriptionScheduleAmendParams.Amendment.discountActions
for the field documentation. -
putExtraParam
Add a key/value pair to `extraParams` map. A map is initialized for the first `put/putAll` call, and subsequent calls add additional key/value pairs to the original map. SeeSubscriptionScheduleAmendParams.Amendment.extraParams
for the field documentation. -
putAllExtraParam
Add all map key/value pairs to `extraParams` map. A map is initialized for the first `put/putAll` call, and subsequent calls add additional key/value pairs to the original map. SeeSubscriptionScheduleAmendParams.Amendment.extraParams
for the field documentation. -
addItemAction
public SubscriptionScheduleAmendParams.Amendment.Builder addItemAction(SubscriptionScheduleAmendParams.Amendment.ItemAction element) Add an element to `itemActions` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. SeeSubscriptionScheduleAmendParams.Amendment.itemActions
for the field documentation. -
addAllItemAction
public SubscriptionScheduleAmendParams.Amendment.Builder addAllItemAction(List<SubscriptionScheduleAmendParams.Amendment.ItemAction> elements) Add all elements to `itemActions` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. SeeSubscriptionScheduleAmendParams.Amendment.itemActions
for the field documentation. -
addMetadataAction
public SubscriptionScheduleAmendParams.Amendment.Builder addMetadataAction(SubscriptionScheduleAmendParams.Amendment.MetadataAction element) Add an element to `metadataActions` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. SeeSubscriptionScheduleAmendParams.Amendment.metadataActions
for the field documentation. -
addAllMetadataAction
public SubscriptionScheduleAmendParams.Amendment.Builder addAllMetadataAction(List<SubscriptionScheduleAmendParams.Amendment.MetadataAction> elements) Add all elements to `metadataActions` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. SeeSubscriptionScheduleAmendParams.Amendment.metadataActions
for the field documentation. -
setProrationBehavior
public SubscriptionScheduleAmendParams.Amendment.Builder setProrationBehavior(SubscriptionScheduleAmendParams.Amendment.ProrationBehavior prorationBehavior) Changes to how Stripe handles prorations during the amendment time span. Affects if and how prorations are created when a future phase starts. In cases where the amendment changes the currently active phase, it is used to determine whether or how to prorate now, at the time of the request. Also supported as a point-in-time operation whenamendment_end
isnull
. -
setSetPauseCollection
public SubscriptionScheduleAmendParams.Amendment.Builder setSetPauseCollection(SubscriptionScheduleAmendParams.Amendment.SetPauseCollection setPauseCollection) Defines how to pause collection for the underlying subscription throughout the duration of the amendment. -
setSetScheduleEnd
public SubscriptionScheduleAmendParams.Amendment.Builder setSetScheduleEnd(SubscriptionScheduleAmendParams.Amendment.SetScheduleEnd setScheduleEnd) Ends the subscription schedule early as dictated by either the accompanying amendment's start or end. -
setTrialSettings
public SubscriptionScheduleAmendParams.Amendment.Builder setTrialSettings(SubscriptionScheduleAmendParams.Amendment.TrialSettings trialSettings) Settings related to subscription trials.
-