public class InvoiceItem extends ApiResource implements HasId, MetadataStore<InvoiceItem>
ApiResource.RequestMethodCHARSET, GSONPRETTY_PRINT_GSON| Constructor and Description |
|---|
InvoiceItem() |
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
canEqual(java.lang.Object other) |
static InvoiceItem |
create(InvoiceItemCreateParams params)
Creates an item to be added to a draft invoice.
|
static InvoiceItem |
create(InvoiceItemCreateParams params,
RequestOptions options)
Creates an item to be added to a draft invoice.
|
static InvoiceItem |
create(java.util.Map<java.lang.String,java.lang.Object> params)
Creates an item to be added to a draft invoice.
|
static InvoiceItem |
create(java.util.Map<java.lang.String,java.lang.Object> params,
RequestOptions options)
Creates an item to be added to a draft invoice.
|
InvoiceItem |
delete()
Deletes an invoice item, removing it from an invoice.
|
InvoiceItem |
delete(java.util.Map<java.lang.String,java.lang.Object> params)
Deletes an invoice item, removing it from an invoice.
|
InvoiceItem |
delete(java.util.Map<java.lang.String,java.lang.Object> params,
RequestOptions options)
Deletes an invoice item, removing it from an invoice.
|
InvoiceItem |
delete(RequestOptions options)
Deletes an invoice item, removing it from an invoice.
|
boolean |
equals(java.lang.Object o) |
java.lang.Long |
getAmount()
Amount (in the
currency specified) of the invoice item. |
java.lang.String |
getCurrency()
Three-letter ISO currency code,
in lowercase.
|
java.lang.String |
getCustomer()
Get ID of expandable
customer object. |
Customer |
getCustomerObject()
Get expanded
customer. |
java.lang.Long |
getDate()
Time at which the object was created.
|
java.lang.Boolean |
getDeleted()
Always true for a deleted object.
|
java.lang.String |
getDescription()
An arbitrary string attached to the object.
|
java.lang.Boolean |
getDiscountable()
If true, discounts will apply to this invoice item.
|
java.util.List<Discount> |
getDiscountObjects()
Get expanded
discounts. |
java.util.List<java.lang.String> |
getDiscounts()
Get IDs of expandable
discounts object list. |
java.lang.String |
getId()
Unique identifier for the object.
|
java.lang.String |
getInvoice()
Get ID of expandable
invoice object. |
Invoice |
getInvoiceObject()
Get expanded
invoice. |
java.lang.Boolean |
getLivemode()
Has the value
true if the object exists in live mode or the value false if the
object exists in test mode. |
java.util.Map<java.lang.String,java.lang.String> |
getMetadata()
Set of key-value pairs that you can attach
to an object.
|
java.lang.String |
getObject()
String representing the object's type.
|
InvoiceLineItemPeriod |
getPeriod() |
Plan |
getPlan()
If the invoice item is a proration, the plan of the subscription that the proration was
computed for.
|
Price |
getPrice()
The price of the invoice item.
|
java.lang.Boolean |
getProration()
Whether the invoice item was created automatically as a proration adjustment when the customer
switched plans.
|
java.lang.Long |
getQuantity()
Quantity of units for the invoice item.
|
java.lang.String |
getSubscription()
Get ID of expandable
subscription object. |
java.lang.String |
getSubscriptionItem()
The subscription item that this invoice item has been created for, if any.
|
Subscription |
getSubscriptionObject()
Get expanded
subscription. |
java.util.List<TaxRate> |
getTaxRates()
The tax rates which apply to the invoice item.
|
java.lang.Boolean |
getUnifiedProration()
For prorations this indicates whether Stripe automatically grouped multiple related debit and
credit line items into a single combined line item.
|
java.lang.Long |
getUnitAmount()
Unit Amount (in the
currency specified) of the invoice item. |
java.math.BigDecimal |
getUnitAmountDecimal()
Same as
unit_amount, but contains a decimal value with at most 12 decimal places. |
int |
hashCode() |
static InvoiceItemCollection |
list(InvoiceItemListParams params)
Returns a list of your invoice items.
|
static InvoiceItemCollection |
list(InvoiceItemListParams params,
RequestOptions options)
Returns a list of your invoice items.
|
static InvoiceItemCollection |
list(java.util.Map<java.lang.String,java.lang.Object> params)
Returns a list of your invoice items.
|
static InvoiceItemCollection |
list(java.util.Map<java.lang.String,java.lang.Object> params,
RequestOptions options)
Returns a list of your invoice items.
|
static InvoiceItem |
retrieve(java.lang.String invoiceitem)
Retrieves the invoice item with the given ID.
|
static InvoiceItem |
retrieve(java.lang.String invoiceitem,
InvoiceItemRetrieveParams params,
RequestOptions options)
Retrieves the invoice item with the given ID.
|
static InvoiceItem |
retrieve(java.lang.String invoiceitem,
java.util.Map<java.lang.String,java.lang.Object> params,
RequestOptions options)
Retrieves the invoice item with the given ID.
|
static InvoiceItem |
retrieve(java.lang.String invoiceitem,
RequestOptions options)
Retrieves the invoice item with the given ID.
|
void |
setAmount(java.lang.Long amount)
Amount (in the
currency specified) of the invoice item. |
void |
setCurrency(java.lang.String currency)
Three-letter ISO currency code,
in lowercase.
|
void |
setCustomer(java.lang.String id) |
void |
setCustomerObject(Customer expandableObject) |
void |
setDate(java.lang.Long date)
Time at which the object was created.
|
void |
setDeleted(java.lang.Boolean deleted)
Always true for a deleted object.
|
void |
setDescription(java.lang.String description)
An arbitrary string attached to the object.
|
void |
setDiscountable(java.lang.Boolean discountable)
If true, discounts will apply to this invoice item.
|
void |
setDiscountObjects(java.util.List<Discount> objs) |
void |
setDiscounts(java.util.List<java.lang.String> ids) |
void |
setId(java.lang.String id)
Unique identifier for the object.
|
void |
setInvoice(java.lang.String id) |
void |
setInvoiceObject(Invoice expandableObject) |
void |
setLivemode(java.lang.Boolean livemode)
Has the value
true if the object exists in live mode or the value false if the
object exists in test mode. |
void |
setMetadata(java.util.Map<java.lang.String,java.lang.String> metadata)
Set of key-value pairs that you can attach
to an object.
|
void |
setObject(java.lang.String object)
String representing the object's type.
|
void |
setPeriod(InvoiceLineItemPeriod period) |
void |
setPlan(Plan plan)
If the invoice item is a proration, the plan of the subscription that the proration was
computed for.
|
void |
setPrice(Price price)
The price of the invoice item.
|
void |
setProration(java.lang.Boolean proration)
Whether the invoice item was created automatically as a proration adjustment when the customer
switched plans.
|
void |
setQuantity(java.lang.Long quantity)
Quantity of units for the invoice item.
|
void |
setSubscription(java.lang.String id) |
void |
setSubscriptionItem(java.lang.String subscriptionItem)
The subscription item that this invoice item has been created for, if any.
|
void |
setSubscriptionObject(Subscription expandableObject) |
void |
setTaxRates(java.util.List<TaxRate> taxRates)
The tax rates which apply to the invoice item.
|
void |
setUnifiedProration(java.lang.Boolean unifiedProration)
For prorations this indicates whether Stripe automatically grouped multiple related debit and
credit line items into a single combined line item.
|
void |
setUnitAmount(java.lang.Long unitAmount)
Unit Amount (in the
currency specified) of the invoice item. |
void |
setUnitAmountDecimal(java.math.BigDecimal unitAmountDecimal)
Same as
unit_amount, but contains a decimal value with at most 12 decimal places. |
InvoiceItem |
update(InvoiceItemUpdateParams params)
Updates the amount or description of an invoice item on an upcoming invoice.
|
InvoiceItem |
update(InvoiceItemUpdateParams params,
RequestOptions options)
Updates the amount or description of an invoice item on an upcoming invoice.
|
InvoiceItem |
update(java.util.Map<java.lang.String,java.lang.Object> params)
Updates the amount or description of an invoice item on an upcoming invoice.
|
InvoiceItem |
update(java.util.Map<java.lang.String,java.lang.Object> params,
RequestOptions options)
Updates the amount or description of an invoice item on an upcoming invoice.
|
checkNullTypedParams, classUrl, classUrl, instanceUrl, instanceUrl, request, request, requestCollection, requestCollection, setExpandableFieldId, setStripeResponseGetter, singleClassUrl, singleClassUrl, subresourceUrl, urlEncode, urlEncodeIdequals, getLastResponse, getRawJsonObject, setLastResponse, toJson, toStringpublic java.lang.String getCustomer()
customer object.public void setCustomer(java.lang.String id)
public Customer getCustomerObject()
customer.public void setCustomerObject(Customer expandableObject)
public java.lang.String getInvoice()
invoice object.public void setInvoice(java.lang.String id)
public Invoice getInvoiceObject()
invoice.public void setInvoiceObject(Invoice expandableObject)
public java.lang.String getSubscription()
subscription object.public void setSubscription(java.lang.String id)
public Subscription getSubscriptionObject()
subscription.public void setSubscriptionObject(Subscription expandableObject)
public java.util.List<java.lang.String> getDiscounts()
discounts object list.public void setDiscounts(java.util.List<java.lang.String> ids)
public java.util.List<Discount> getDiscountObjects()
discounts.public void setDiscountObjects(java.util.List<Discount> objs)
public static InvoiceItemCollection list(java.util.Map<java.lang.String,java.lang.Object> params) throws StripeException
StripeExceptionpublic static InvoiceItemCollection list(java.util.Map<java.lang.String,java.lang.Object> params, RequestOptions options) throws StripeException
StripeExceptionpublic static InvoiceItemCollection list(InvoiceItemListParams params) throws StripeException
StripeExceptionpublic static InvoiceItemCollection list(InvoiceItemListParams params, RequestOptions options) throws StripeException
StripeExceptionpublic static InvoiceItem create(java.util.Map<java.lang.String,java.lang.Object> params) throws StripeException
StripeExceptionpublic static InvoiceItem create(java.util.Map<java.lang.String,java.lang.Object> params, RequestOptions options) throws StripeException
StripeExceptionpublic static InvoiceItem create(InvoiceItemCreateParams params) throws StripeException
StripeExceptionpublic static InvoiceItem create(InvoiceItemCreateParams params, RequestOptions options) throws StripeException
StripeExceptionpublic static InvoiceItem retrieve(java.lang.String invoiceitem) throws StripeException
StripeExceptionpublic static InvoiceItem retrieve(java.lang.String invoiceitem, RequestOptions options) throws StripeException
StripeExceptionpublic static InvoiceItem retrieve(java.lang.String invoiceitem, java.util.Map<java.lang.String,java.lang.Object> params, RequestOptions options) throws StripeException
StripeExceptionpublic static InvoiceItem retrieve(java.lang.String invoiceitem, InvoiceItemRetrieveParams params, RequestOptions options) throws StripeException
StripeExceptionpublic InvoiceItem update(java.util.Map<java.lang.String,java.lang.Object> params) throws StripeException
update in interface MetadataStore<InvoiceItem>StripeExceptionpublic InvoiceItem update(java.util.Map<java.lang.String,java.lang.Object> params, RequestOptions options) throws StripeException
update in interface MetadataStore<InvoiceItem>StripeExceptionpublic InvoiceItem update(InvoiceItemUpdateParams params) throws StripeException
StripeExceptionpublic InvoiceItem update(InvoiceItemUpdateParams params, RequestOptions options) throws StripeException
StripeExceptionpublic InvoiceItem delete() throws StripeException
StripeExceptionpublic InvoiceItem delete(RequestOptions options) throws StripeException
StripeExceptionpublic InvoiceItem delete(java.util.Map<java.lang.String,java.lang.Object> params) throws StripeException
StripeExceptionpublic InvoiceItem delete(java.util.Map<java.lang.String,java.lang.Object> params, RequestOptions options) throws StripeException
StripeExceptionpublic java.lang.Long getAmount()
currency specified) of the invoice item. This should always be equal to
unit_amount * quantity.public java.lang.String getCurrency()
public java.lang.Long getDate()
public java.lang.Boolean getDeleted()
public java.lang.String getDescription()
public java.lang.Boolean getDiscountable()
public java.lang.Boolean getLivemode()
true if the object exists in live mode or the value false if the
object exists in test mode.public java.lang.String getObject()
Equal to invoiceitem.
public InvoiceLineItemPeriod getPeriod()
public Plan getPlan()
public Price getPrice()
public java.lang.Boolean getProration()
public java.lang.Long getQuantity()
public java.lang.String getSubscriptionItem()
public java.util.List<TaxRate> getTaxRates()
default_tax_rates on the
invoice do not apply to this invoice item.public java.lang.Boolean getUnifiedProration()
public java.lang.Long getUnitAmount()
currency specified) of the invoice item.public java.math.BigDecimal getUnitAmountDecimal()
unit_amount, but contains a decimal value with at most 12 decimal places.public void setAmount(java.lang.Long amount)
currency specified) of the invoice item. This should always be equal to
unit_amount * quantity.public void setCurrency(java.lang.String currency)
public void setDate(java.lang.Long date)
public void setDeleted(java.lang.Boolean deleted)
public void setDescription(java.lang.String description)
public void setDiscountable(java.lang.Boolean discountable)
public void setId(java.lang.String id)
public void setLivemode(java.lang.Boolean livemode)
true if the object exists in live mode or the value false if the
object exists in test mode.public void setMetadata(java.util.Map<java.lang.String,java.lang.String> metadata)
public void setObject(java.lang.String object)
Equal to invoiceitem.
public void setPeriod(InvoiceLineItemPeriod period)
public void setPlan(Plan plan)
public void setPrice(Price price)
public void setProration(java.lang.Boolean proration)
public void setQuantity(java.lang.Long quantity)
public void setSubscriptionItem(java.lang.String subscriptionItem)
public void setTaxRates(java.util.List<TaxRate> taxRates)
default_tax_rates on the
invoice do not apply to this invoice item.public void setUnifiedProration(java.lang.Boolean unifiedProration)
public void setUnitAmount(java.lang.Long unitAmount)
currency specified) of the invoice item.public void setUnitAmountDecimal(java.math.BigDecimal unitAmountDecimal)
unit_amount, but contains a decimal value with at most 12 decimal places.public boolean equals(java.lang.Object o)
equals in class java.lang.Objectprotected boolean canEqual(java.lang.Object other)
public int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String getId()
public java.util.Map<java.lang.String,java.lang.String> getMetadata()
getMetadata in interface MetadataStore<InvoiceItem>