Package com.xero.models.accounting
Class Payment
java.lang.Object
com.xero.models.accounting.Payment
public class Payment extends Object
Payment
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classPayment.PaymentTypeEnumSee Payment Types.static classPayment.StatusEnumThe status of the payment. -
Constructor Summary
Constructors Constructor Description Payment() -
Method Summary
Modifier and Type Method Description Paymentaccount(Account account)PaymentaddValidationErrorsItem(ValidationError validationErrorsItem)Paymentamount(Double amount)PaymentbankAccountNumber(String bankAccountNumber)Paymentcode(String code)PaymentcreditNote(CreditNote creditNote)PaymentcreditNoteNumber(String creditNoteNumber)PaymentcurrencyRate(Double currencyRate)Paymentdate(String date)Paymentdetails(String details)booleanequals(Object o)AccountgetAccount()Get accountDoublegetAmount()The amount of the payment.StringgetBankAccountNumber()The suppliers bank account number the payment is being made toStringgetCode()Code of account you are using to make the payment e.g.CreditNotegetCreditNote()Get creditNoteStringgetCreditNoteNumber()Number of invoice or credit note you are applying payment to e.g.DoublegetCurrencyRate()Exchange rate when payment is received.StringgetDate()Date the payment is being made (YYYY-MM-DD) e.g.org.threeten.bp.LocalDategetDateAsDate()StringgetDetails()The information to appear on the supplier's bank accountBooleangetHasAccount()A boolean to indicate if a contact has an validation errorsBooleangetHasValidationErrors()A boolean to indicate if a contact has an validation errorsInvoicegetInvoice()Get invoiceStringgetInvoiceNumber()Number of invoice or credit note you are applying payment to e.g.INV-4003BooleangetIsReconciled()An optional parameter for the payment.OverpaymentgetOverpayment()Get overpaymentStringgetParticulars()The suppliers bank account number the payment is being made toUUIDgetPaymentID()The Xero identifier for an Payment e.g.Payment.PaymentTypeEnumgetPaymentType()See Payment Types.PrepaymentgetPrepayment()Get prepaymentStringgetReference()An optional description for the payment e.g.Payment.StatusEnumgetStatus()The status of the payment.StringgetStatusAttributeString()A string to indicate if a invoice statusStringgetUpdatedDateUTC()UTC timestamp of last update to the paymentorg.threeten.bp.OffsetDateTimegetUpdatedDateUTCAsDate()List<ValidationError>getValidationErrors()Displays array of validation error messages from the APIPaymenthasAccount(Boolean hasAccount)inthashCode()PaymenthasValidationErrors(Boolean hasValidationErrors)Paymentinvoice(Invoice invoice)PaymentinvoiceNumber(String invoiceNumber)PaymentisReconciled(Boolean isReconciled)Paymentoverpayment(Overpayment overpayment)Paymentparticulars(String particulars)PaymentpaymentID(UUID paymentID)Paymentprepayment(Prepayment prepayment)Paymentreference(String reference)voidsetAccount(Account account)voidsetAmount(Double amount)voidsetBankAccountNumber(String bankAccountNumber)voidsetCode(String code)voidsetCreditNote(CreditNote creditNote)voidsetCreditNoteNumber(String creditNoteNumber)voidsetCurrencyRate(Double currencyRate)voidsetDate(String date)voidsetDate(org.threeten.bp.LocalDate date)voidsetDetails(String details)voidsetHasAccount(Boolean hasAccount)voidsetHasValidationErrors(Boolean hasValidationErrors)voidsetInvoice(Invoice invoice)voidsetInvoiceNumber(String invoiceNumber)voidsetIsReconciled(Boolean isReconciled)voidsetOverpayment(Overpayment overpayment)voidsetParticulars(String particulars)voidsetPaymentID(UUID paymentID)voidsetPrepayment(Prepayment prepayment)voidsetReference(String reference)voidsetStatus(Payment.StatusEnum status)voidsetStatusAttributeString(String statusAttributeString)voidsetValidationErrors(List<ValidationError> validationErrors)Paymentstatus(Payment.StatusEnum status)PaymentstatusAttributeString(String statusAttributeString)StringtoString()PaymentvalidationErrors(List<ValidationError> validationErrors)
-
Constructor Details
-
Payment
public Payment()
-
-
Method Details
-
invoice
-
getInvoice
Get invoice- Returns:
- invoice
-
setInvoice
-
creditNote
-
getCreditNote
Get creditNote- Returns:
- creditNote
-
setCreditNote
-
prepayment
-
getPrepayment
Get prepayment- Returns:
- prepayment
-
setPrepayment
-
overpayment
-
getOverpayment
Get overpayment- Returns:
- overpayment
-
setOverpayment
-
invoiceNumber
-
getInvoiceNumber
Number of invoice or credit note you are applying payment to e.g.INV-4003- Returns:
- invoiceNumber
-
setInvoiceNumber
-
creditNoteNumber
-
getCreditNoteNumber
Number of invoice or credit note you are applying payment to e.g. INV-4003- Returns:
- creditNoteNumber
-
setCreditNoteNumber
-
account
-
getAccount
Get account- Returns:
- account
-
setAccount
-
code
-
getCode
Code of account you are using to make the payment e.g. 001 (note- not all accounts have a code value)- Returns:
- code
-
setCode
-
date
-
getDate
Date the payment is being made (YYYY-MM-DD) e.g. 2009-09-06- Returns:
- date
-
getDateAsDate
public org.threeten.bp.LocalDate getDateAsDate() -
setDate
-
setDate
public void setDate(org.threeten.bp.LocalDate date) -
currencyRate
-
getCurrencyRate
Exchange rate when payment is received. Only used for non base currency invoices and credit notes e.g. 0.7500- Returns:
- currencyRate
-
setCurrencyRate
-
amount
-
getAmount
The amount of the payment. Must be less than or equal to the outstanding amount owing on the invoice e.g. 200.00- Returns:
- amount
-
setAmount
-
reference
-
getReference
An optional description for the payment e.g. Direct Debit- Returns:
- reference
-
setReference
-
isReconciled
-
getIsReconciled
An optional parameter for the payment. A boolean indicating whether you would like the payment to be created as reconciled when using PUT, or whether a payment has been reconciled when using GET- Returns:
- isReconciled
-
setIsReconciled
-
status
-
getStatus
The status of the payment.- Returns:
- status
-
setStatus
-
getPaymentType
See Payment Types.- Returns:
- paymentType
-
getUpdatedDateUTC
UTC timestamp of last update to the payment- Returns:
- updatedDateUTC
-
getUpdatedDateUTCAsDate
public org.threeten.bp.OffsetDateTime getUpdatedDateUTCAsDate() -
paymentID
-
getPaymentID
The Xero identifier for an Payment e.g. 297c2dc5-cc47-4afd-8ec8-74990b8761e9- Returns:
- paymentID
-
setPaymentID
-
bankAccountNumber
-
getBankAccountNumber
The suppliers bank account number the payment is being made to- Returns:
- bankAccountNumber
-
setBankAccountNumber
-
particulars
-
getParticulars
The suppliers bank account number the payment is being made to- Returns:
- particulars
-
setParticulars
-
details
-
getDetails
The information to appear on the supplier's bank account- Returns:
- details
-
setDetails
-
hasAccount
-
getHasAccount
A boolean to indicate if a contact has an validation errors- Returns:
- hasAccount
-
setHasAccount
-
hasValidationErrors
-
getHasValidationErrors
A boolean to indicate if a contact has an validation errors- Returns:
- hasValidationErrors
-
setHasValidationErrors
-
statusAttributeString
-
getStatusAttributeString
A string to indicate if a invoice status- Returns:
- statusAttributeString
-
setStatusAttributeString
-
validationErrors
-
addValidationErrorsItem
-
getValidationErrors
Displays array of validation error messages from the API- Returns:
- validationErrors
-
setValidationErrors
-
equals
-
hashCode
public int hashCode() -
toString
-