Package com.stripe.model
Class InvoiceLineItem
java.lang.Object
com.stripe.model.StripeObject
com.stripe.net.ApiResource
com.stripe.model.InvoiceLineItem
- All Implemented Interfaces:
HasId,MetadataStore<InvoiceLineItem>,StripeActiveObject,StripeObjectInterface
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic classstatic classstatic classCredited invoice line items.Nested classes/interfaces inherited from class com.stripe.net.ApiResource
ApiResource.RequestMethod -
Field Summary
Fields inherited from class com.stripe.net.ApiResource
CHARSET, GSON, INTERNAL_GSONFields inherited from class com.stripe.model.StripeObject
PRETTY_PRINT_GSON -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanbooleanThe amount, in cents (or local equivalent).The integer amount in cents (or local equivalent) representing the amount for this line item, excluding all tax and discounts.Three-letter ISO currency code, in lowercase.An arbitrary string attached to the object.If true, discounts will apply to this line item.The amount of discount calculated per discount for this line item.Get expandeddiscounts.Get IDs of expandablediscountsobject list.getId()Unique identifier for the object.The ID of the invoice that contains this line item.Get ID of expandableinvoiceItemobject.Get expandedinvoiceItem.Has the valuetrueif the object exists in live mode or the valuefalseif the object exists in test mode.Set of key-value pairs that you can attach to an object.String representing the object's type.getPlan()The plan of the subscription, if the line item is a subscription or a proration.getPrice()The price of the line item.Whether this is a proration.Additional details for proration line items.The quantity of the subscription, if the line item is a subscription or a proration.Get ID of expandablesubscriptionobject.Get ID of expandablesubscriptionItemobject.Get expandedsubscriptionItem.Get expandedsubscription.The amount of tax calculated per tax rate for this line item.The tax rates which apply to the line item.getType()A string identifying the type of the source of this line item, either aninvoiceitemor asubscription.The amount in cents (or local equivalent) representing the unit amount for this line item, excluding all tax and discounts.inthashCode()voidThe amount, in cents (or local equivalent).voidsetAmountExcludingTax(Long amountExcludingTax) The integer amount in cents (or local equivalent) representing the amount for this line item, excluding all tax and discounts.voidsetCurrency(String currency) Three-letter ISO currency code, in lowercase.voidsetDescription(String description) An arbitrary string attached to the object.voidsetDiscountable(Boolean discountable) If true, discounts will apply to this line item.voidsetDiscountAmounts(List<InvoiceLineItem.DiscountAmount> discountAmounts) The amount of discount calculated per discount for this line item.voidsetDiscountObjects(List<Discount> objs) voidsetDiscounts(List<String> ids) voidUnique identifier for the object.voidsetInvoice(String invoice) The ID of the invoice that contains this line item.voidsetInvoiceItem(String id) voidsetInvoiceItemObject(InvoiceItem expandableObject) voidsetLivemode(Boolean livemode) Has the valuetrueif the object exists in live mode or the valuefalseif the object exists in test mode.voidsetMetadata(Map<String, String> metadata) Set of key-value pairs that you can attach to an object.voidString representing the object's type.voidsetPeriod(InvoiceLineItem.Period period) voidThe plan of the subscription, if the line item is a subscription or a proration.voidThe price of the line item.voidsetProration(Boolean proration) Whether this is a proration.voidsetProrationDetails(InvoiceLineItem.ProrationDetails prorationDetails) Additional details for proration line items.voidsetQuantity(Long quantity) The quantity of the subscription, if the line item is a subscription or a proration.voidsetResponseGetter(StripeResponseGetter responseGetter) Method is used by the containing object orStripeResponseGetterimplementations to set theStripeResponseGetterinstance used to make further requests.voidvoidvoidsetSubscriptionItemObject(SubscriptionItem expandableObject) voidsetSubscriptionObject(Subscription expandableObject) voidsetTaxAmounts(List<InvoiceLineItem.TaxAmount> taxAmounts) The amount of tax calculated per tax rate for this line item.voidsetTaxRates(List<TaxRate> taxRates) The tax rates which apply to the line item.voidA string identifying the type of the source of this line item, either aninvoiceitemor asubscription.voidsetUnitAmountExcludingTax(BigDecimal unitAmountExcludingTax) The amount in cents (or local equivalent) representing the unit amount for this line item, excluding all tax and discounts.update(InvoiceLineItemUpdateParams params) Updates an invoice’s line item.update(InvoiceLineItemUpdateParams params, RequestOptions options) Updates an invoice’s line item.Updates an invoice’s line item.update(Map<String, Object> params, RequestOptions options) Updates an invoice’s line item.Methods inherited from class com.stripe.net.ApiResource
checkNullTypedParams, getGlobalResponseGetter, getResponseGetter, setExpandableFieldId, setStripeResponseGetter, urlEncode, urlEncodeIdMethods inherited from class com.stripe.model.StripeObject
deserializeStripeObject, deserializeStripeObject, deserializeStripeObject, equals, getLastResponse, getRawJsonObject, setLastResponse, toJson, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.stripe.model.StripeActiveObject
trySetResponseGetter
-
Constructor Details
-
InvoiceLineItem
public InvoiceLineItem()
-
-
Method Details
-
getInvoiceItem
Get ID of expandableinvoiceItemobject. -
setInvoiceItem
-
getInvoiceItemObject
Get expandedinvoiceItem. -
setInvoiceItemObject
-
getSubscription
Get ID of expandablesubscriptionobject. -
setSubscription
-
getSubscriptionObject
Get expandedsubscription. -
setSubscriptionObject
-
getSubscriptionItem
Get ID of expandablesubscriptionItemobject. -
setSubscriptionItem
-
getSubscriptionItemObject
Get expandedsubscriptionItem. -
setSubscriptionItemObject
-
getDiscounts
Get IDs of expandablediscountsobject list. -
setDiscounts
-
getDiscountObjects
Get expandeddiscounts. -
setDiscountObjects
-
update
Updates an invoice’s line item. Some fields, such astax_amounts, only live on the invoice line item, so they can only be updated through this endpoint. Other fields, such asamount, live on both the invoice item and the invoice line item, so updates on this endpoint will propagate to the invoice item as well. Updating an invoice’s line item is only possible before the invoice is finalized.- Specified by:
updatein interfaceMetadataStore<InvoiceLineItem>- Throws:
StripeException
-
update
public InvoiceLineItem update(Map<String, Object> params, RequestOptions options) throws StripeExceptionUpdates an invoice’s line item. Some fields, such astax_amounts, only live on the invoice line item, so they can only be updated through this endpoint. Other fields, such asamount, live on both the invoice item and the invoice line item, so updates on this endpoint will propagate to the invoice item as well. Updating an invoice’s line item is only possible before the invoice is finalized.- Specified by:
updatein interfaceMetadataStore<InvoiceLineItem>- Throws:
StripeException
-
update
Updates an invoice’s line item. Some fields, such astax_amounts, only live on the invoice line item, so they can only be updated through this endpoint. Other fields, such asamount, live on both the invoice item and the invoice line item, so updates on this endpoint will propagate to the invoice item as well. Updating an invoice’s line item is only possible before the invoice is finalized.- Throws:
StripeException
-
update
public InvoiceLineItem update(InvoiceLineItemUpdateParams params, RequestOptions options) throws StripeException Updates an invoice’s line item. Some fields, such astax_amounts, only live on the invoice line item, so they can only be updated through this endpoint. Other fields, such asamount, live on both the invoice item and the invoice line item, so updates on this endpoint will propagate to the invoice item as well. Updating an invoice’s line item is only possible before the invoice is finalized.- Throws:
StripeException
-
setResponseGetter
Description copied from interface:StripeActiveObjectMethod is used by the containing object orStripeResponseGetterimplementations to set theStripeResponseGetterinstance used to make further requests.- Specified by:
setResponseGetterin interfaceStripeActiveObject- Overrides:
setResponseGetterin classApiResource- Parameters:
responseGetter- theStripeResponseGetterinstance to use for making further requests.
-
getAmount
The amount, in cents (or local equivalent). -
getAmountExcludingTax
The integer amount in cents (or local equivalent) representing the amount for this line item, excluding all tax and discounts. -
getCurrency
Three-letter ISO currency code, in lowercase. Must be a supported currency. -
getDescription
An arbitrary string attached to the object. Often useful for displaying to users. -
getDiscountAmounts
The amount of discount calculated per discount for this line item. -
getDiscountable
If true, discounts will apply to this line item. Always false for prorations. -
getInvoice
The ID of the invoice that contains this line item. -
getLivemode
Has the valuetrueif the object exists in live mode or the valuefalseif the object exists in test mode. -
getObject
String representing the object's type. Objects of the same type share the same value.Equal to
line_item. -
getPeriod
-
getPlan
The plan of the subscription, if the line item is a subscription or a proration. -
getPrice
The price of the line item. -
getProration
Whether this is a proration. -
getProrationDetails
Additional details for proration line items. -
getQuantity
The quantity of the subscription, if the line item is a subscription or a proration. -
getTaxAmounts
The amount of tax calculated per tax rate for this line item. -
getTaxRates
The tax rates which apply to the line item. -
getType
A string identifying the type of the source of this line item, either aninvoiceitemor asubscription.One of
invoiceitem, orsubscription. -
getUnitAmountExcludingTax
The amount in cents (or local equivalent) representing the unit amount for this line item, excluding all tax and discounts. -
setAmount
The amount, in cents (or local equivalent). -
setAmountExcludingTax
The integer amount in cents (or local equivalent) representing the amount for this line item, excluding all tax and discounts. -
setCurrency
Three-letter ISO currency code, in lowercase. Must be a supported currency. -
setDescription
An arbitrary string attached to the object. Often useful for displaying to users. -
setDiscountAmounts
The amount of discount calculated per discount for this line item. -
setDiscountable
If true, discounts will apply to this line item. Always false for prorations. -
setId
Unique identifier for the object. -
setInvoice
The ID of the invoice that contains this line item. -
setLivemode
Has the valuetrueif the object exists in live mode or the valuefalseif the object exists in test mode. -
setMetadata
Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Note that for line items withtype=subscription,metadatareflects the current metadata from the subscription associated with the line item, unless the invoice line was directly updated with different metadata after creation. -
setObject
String representing the object's type. Objects of the same type share the same value.Equal to
line_item. -
setPeriod
-
setPlan
The plan of the subscription, if the line item is a subscription or a proration. -
setPrice
The price of the line item. -
setProration
Whether this is a proration. -
setProrationDetails
Additional details for proration line items. -
setQuantity
The quantity of the subscription, if the line item is a subscription or a proration. -
setTaxAmounts
The amount of tax calculated per tax rate for this line item. -
setTaxRates
The tax rates which apply to the line item. -
setType
A string identifying the type of the source of this line item, either aninvoiceitemor asubscription.One of
invoiceitem, orsubscription. -
setUnitAmountExcludingTax
The amount in cents (or local equivalent) representing the unit amount for this line item, excluding all tax and discounts. -
equals
-
canEqual
-
hashCode
public int hashCode() -
getId
Unique identifier for the object. -
getMetadata
Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Note that for line items withtype=subscription,metadatareflects the current metadata from the subscription associated with the line item, unless the invoice line was directly updated with different metadata after creation.- Specified by:
getMetadatain interfaceMetadataStore<InvoiceLineItem>
-