Class InvoiceLineItem

java.lang.Object
com.stripe.model.StripeObject
com.stripe.model.InvoiceLineItem
All Implemented Interfaces:
HasId, StripeObjectInterface

public class InvoiceLineItem extends StripeObject implements HasId
  • Constructor Details

    • InvoiceLineItem

      public InvoiceLineItem()
  • Method Details

    • getDiscounts

      public List<String> getDiscounts()
      Get IDs of expandable discounts object list.
    • setDiscounts

      public void setDiscounts(List<String> ids)
    • getDiscountObjects

      public List<Discount> getDiscountObjects()
      Get expanded discounts.
    • setDiscountObjects

      public void setDiscountObjects(List<Discount> objs)
    • getAmount

      public Long getAmount()
      The amount, in %s.
    • getAmountExcludingTax

      public Long getAmountExcludingTax()
      The integer amount in %s representing the amount for this line item, excluding all tax and discounts.
    • getCurrency

      public String getCurrency()
      Three-letter ISO currency code, in lowercase. Must be a supported currency.
    • getDescription

      public String getDescription()
      An arbitrary string attached to the object. Often useful for displaying to users.
    • getDiscountAmounts

      public List<InvoiceLineItem.DiscountAmount> getDiscountAmounts()
      The amount of discount calculated per discount for this line item.
    • getDiscountable

      public Boolean getDiscountable()
      If true, discounts will apply to this line item. Always false for prorations.
    • getInvoiceItem

      public String getInvoiceItem()
      The ID of the invoice item associated with this line item if any.
    • getLivemode

      public Boolean getLivemode()
      Has the value true if the object exists in live mode or the value false if the object exists in test mode.
    • getMetadata

      public Map<String,String> 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 with type=subscription this will reflect the metadata of the subscription that caused the line item to be created.
    • getObject

      public String getObject()
      String representing the object's type. Objects of the same type share the same value.

      Equal to line_item.

    • getPeriod

      public InvoiceLineItem.Period getPeriod()
    • getPlan

      public Plan getPlan()
      The plan of the subscription, if the line item is a subscription or a proration.
    • getPrice

      public Price getPrice()
      The price of the line item.
    • getProration

      public Boolean getProration()
      Whether this is a proration.
    • getProrationDetails

      public InvoiceLineItem.ProrationDetails getProrationDetails()
      Additional details for proration line items.
    • getQuantity

      public Long getQuantity()
      The quantity of the subscription, if the line item is a subscription or a proration.
    • getSubscription

      public String getSubscription()
      The subscription that the invoice item pertains to, if any.
    • getSubscriptionItem

      public String getSubscriptionItem()
      The subscription item that generated this invoice item. Left empty if the line item is not an explicit result of a subscription.
    • getTaxAmounts

      public List<InvoiceLineItem.TaxAmount> getTaxAmounts()
      The amount of tax calculated per tax rate for this line item.
    • getTaxRates

      public List<TaxRate> getTaxRates()
      The tax rates which apply to the line item.
    • getType

      public String getType()
      A string identifying the type of the source of this line item, either an invoiceitem or a subscription.

      One of invoiceitem, or subscription.

    • getUnitAmountExcludingTax

      public BigDecimal getUnitAmountExcludingTax()
      The amount in %s representing the unit amount for this line item, excluding all tax and discounts.
    • setAmount

      public void setAmount(Long amount)
      The amount, in %s.
    • setAmountExcludingTax

      public void setAmountExcludingTax(Long amountExcludingTax)
      The integer amount in %s representing the amount for this line item, excluding all tax and discounts.
    • setCurrency

      public void setCurrency(String currency)
      Three-letter ISO currency code, in lowercase. Must be a supported currency.
    • setDescription

      public void setDescription(String description)
      An arbitrary string attached to the object. Often useful for displaying to users.
    • setDiscountAmounts

      public void setDiscountAmounts(List<InvoiceLineItem.DiscountAmount> discountAmounts)
      The amount of discount calculated per discount for this line item.
    • setDiscountable

      public void setDiscountable(Boolean discountable)
      If true, discounts will apply to this line item. Always false for prorations.
    • setId

      public void setId(String id)
      Unique identifier for the object.
    • setInvoiceItem

      public void setInvoiceItem(String invoiceItem)
      The ID of the invoice item associated with this line item if any.
    • setLivemode

      public void setLivemode(Boolean livemode)
      Has the value true if the object exists in live mode or the value false if the object exists in test mode.
    • setMetadata

      public void setMetadata(Map<String,String> metadata)
      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 with type=subscription this will reflect the metadata of the subscription that caused the line item to be created.
    • setObject

      public void setObject(String object)
      String representing the object's type. Objects of the same type share the same value.

      Equal to line_item.

    • setPeriod

      public void setPeriod(InvoiceLineItem.Period period)
    • setPlan

      public void setPlan(Plan plan)
      The plan of the subscription, if the line item is a subscription or a proration.
    • setPrice

      public void setPrice(Price price)
      The price of the line item.
    • setProration

      public void setProration(Boolean proration)
      Whether this is a proration.
    • setProrationDetails

      public void setProrationDetails(InvoiceLineItem.ProrationDetails prorationDetails)
      Additional details for proration line items.
    • setQuantity

      public void setQuantity(Long quantity)
      The quantity of the subscription, if the line item is a subscription or a proration.
    • setSubscription

      public void setSubscription(String subscription)
      The subscription that the invoice item pertains to, if any.
    • setSubscriptionItem

      public void setSubscriptionItem(String subscriptionItem)
      The subscription item that generated this invoice item. Left empty if the line item is not an explicit result of a subscription.
    • setTaxAmounts

      public void setTaxAmounts(List<InvoiceLineItem.TaxAmount> taxAmounts)
      The amount of tax calculated per tax rate for this line item.
    • setTaxRates

      public void setTaxRates(List<TaxRate> taxRates)
      The tax rates which apply to the line item.
    • setType

      public void setType(String type)
      A string identifying the type of the source of this line item, either an invoiceitem or a subscription.

      One of invoiceitem, or subscription.

    • setUnitAmountExcludingTax

      public void setUnitAmountExcludingTax(BigDecimal unitAmountExcludingTax)
      The amount in %s representing the unit amount for this line item, excluding all tax and discounts.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(Object other)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • getId

      public String getId()
      Unique identifier for the object.
      Specified by:
      getId in interface HasId