Package com.xero.models.accounting
Class BatchPayment
- java.lang.Object
-
- com.xero.models.accounting.BatchPayment
-
public class BatchPayment extends Object
BatchPayment
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classBatchPayment.StatusEnumAUTHORISED or DELETED (read-only).static classBatchPayment.TypeEnumPAYBATCH for bill payments or RECBATCH for sales invoice payments (read-only)
-
Constructor Summary
Constructors Constructor Description BatchPayment()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BatchPaymentaccount(Account account)accountBatchPaymentaddPaymentsItem(Payment paymentsItem)An array of paymentsBatchPaymentaddValidationErrorsItem(ValidationError validationErrorsItem)Displays array of validation error messages from the APIBatchPaymentamount(Double amount)The amount of the payment.BatchPaymentcode(String code)(NZ Only) Optional references for the batch payment transaction.BatchPaymentdate(String date)Date the payment is being made (YYYY-MM-DD) e.g.BatchPaymentdateString(String dateString)Date the payment is being made (YYYY-MM-DD) e.g.BatchPaymentdetails(String details)(Non-NZ Only) These details are sent to the org’s bank as a reference for the batch payment transaction.booleanequals(Object o)AccountgetAccount()Get accountDoublegetAmount()The amount of the payment.UUIDgetBatchPaymentID()The Xero generated unique identifier for the bank transaction (read-only)StringgetCode()(NZ Only) Optional references for the batch payment transaction.StringgetDate()Date the payment is being made (YYYY-MM-DD) e.g.org.threeten.bp.LocalDategetDateAsDate()Date the payment is being made (YYYY-MM-DD) e.g.StringgetDateString()Date the payment is being made (YYYY-MM-DD) e.g.StringgetDetails()(Non-NZ Only) These details are sent to the org’s bank as a reference for the batch payment transaction.StringgetIsReconciled()Booelan that tells you if the batch payment has been reconciled (read-only)StringgetNarrative()(UK Only) Only shows on the statement line in Xero.StringgetParticulars()(NZ Only) Optional references for the batch payment transaction.List<Payment>getPayments()An array of paymentsStringgetReference()(NZ Only) Optional references for the batch payment transaction.BatchPayment.StatusEnumgetStatus()AUTHORISED or DELETED (read-only).StringgetTotalAmount()The total of the payments that make up the batch (read-only)BatchPayment.TypeEnumgetType()PAYBATCH for bill payments or RECBATCH for sales invoice payments (read-only)StringgetUpdatedDateUTC()UTC timestamp of last update to the paymentorg.threeten.bp.OffsetDateTimegetUpdatedDateUTCAsDate()UTC timestamp of last update to the paymentList<ValidationError>getValidationErrors()Displays array of validation error messages from the APIinthashCode()BatchPaymentnarrative(String narrative)(UK Only) Only shows on the statement line in Xero.BatchPaymentparticulars(String particulars)(NZ Only) Optional references for the batch payment transaction.BatchPaymentpayments(List<Payment> payments)An array of paymentsBatchPaymentreference(String reference)(NZ Only) Optional references for the batch payment transaction.voidsetAccount(Account account)accountvoidsetAmount(Double amount)The amount of the payment.voidsetCode(String code)(NZ Only) Optional references for the batch payment transaction.voidsetDate(String date)Date the payment is being made (YYYY-MM-DD) e.g.voidsetDate(org.threeten.bp.LocalDate date)Date the payment is being made (YYYY-MM-DD) e.g.voidsetDateString(String dateString)Date the payment is being made (YYYY-MM-DD) e.g.voidsetDetails(String details)(Non-NZ Only) These details are sent to the org’s bank as a reference for the batch payment transaction.voidsetNarrative(String narrative)(UK Only) Only shows on the statement line in Xero.voidsetParticulars(String particulars)(NZ Only) Optional references for the batch payment transaction.voidsetPayments(List<Payment> payments)An array of paymentsvoidsetReference(String reference)(NZ Only) Optional references for the batch payment transaction.voidsetValidationErrors(List<ValidationError> validationErrors)Displays array of validation error messages from the APIStringtoString()BatchPaymentvalidationErrors(List<ValidationError> validationErrors)Displays array of validation error messages from the API
-
-
-
Method Detail
-
account
public BatchPayment account(Account account)
account- Parameters:
account- Account- Returns:
- BatchPayment
-
getAccount
public Account getAccount()
Get account- Returns:
- account
-
setAccount
public void setAccount(Account account)
account- Parameters:
account- Account
-
reference
public BatchPayment reference(String reference)
(NZ Only) Optional references for the batch payment transaction. It will also show with the batch payment transaction in the bank reconciliation Find & Match screen. Depending on your individual bank, the detail may also show on the bank statement you import into Xero.- Parameters:
reference- String- Returns:
- BatchPayment
-
getReference
public String getReference()
(NZ Only) Optional references for the batch payment transaction. It will also show with the batch payment transaction in the bank reconciliation Find & Match screen. Depending on your individual bank, the detail may also show on the bank statement you import into Xero.- Returns:
- reference
-
setReference
public void setReference(String reference)
(NZ Only) Optional references for the batch payment transaction. It will also show with the batch payment transaction in the bank reconciliation Find & Match screen. Depending on your individual bank, the detail may also show on the bank statement you import into Xero.- Parameters:
reference- String
-
particulars
public BatchPayment particulars(String particulars)
(NZ Only) Optional references for the batch payment transaction. It will also show with the batch payment transaction in the bank reconciliation Find & Match screen. Depending on your individual bank, the detail may also show on the bank statement you import into Xero.- Parameters:
particulars- String- Returns:
- BatchPayment
-
getParticulars
public String getParticulars()
(NZ Only) Optional references for the batch payment transaction. It will also show with the batch payment transaction in the bank reconciliation Find & Match screen. Depending on your individual bank, the detail may also show on the bank statement you import into Xero.- Returns:
- particulars
-
setParticulars
public void setParticulars(String particulars)
(NZ Only) Optional references for the batch payment transaction. It will also show with the batch payment transaction in the bank reconciliation Find & Match screen. Depending on your individual bank, the detail may also show on the bank statement you import into Xero.- Parameters:
particulars- String
-
code
public BatchPayment code(String code)
(NZ Only) Optional references for the batch payment transaction. It will also show with the batch payment transaction in the bank reconciliation Find & Match screen. Depending on your individual bank, the detail may also show on the bank statement you import into Xero.- Parameters:
code- String- Returns:
- BatchPayment
-
getCode
public String getCode()
(NZ Only) Optional references for the batch payment transaction. It will also show with the batch payment transaction in the bank reconciliation Find & Match screen. Depending on your individual bank, the detail may also show on the bank statement you import into Xero.- Returns:
- code
-
setCode
public void setCode(String code)
(NZ Only) Optional references for the batch payment transaction. It will also show with the batch payment transaction in the bank reconciliation Find & Match screen. Depending on your individual bank, the detail may also show on the bank statement you import into Xero.- Parameters:
code- String
-
details
public BatchPayment details(String details)
(Non-NZ Only) These details are sent to the org’s bank as a reference for the batch payment transaction. They will also show with the batch payment transaction in the bank reconciliation Find & Match screen. Depending on your individual bank, the detail may also show on the bank statement imported into Xero. Maximum field length = 18- Parameters:
details- String- Returns:
- BatchPayment
-
getDetails
public String getDetails()
(Non-NZ Only) These details are sent to the org’s bank as a reference for the batch payment transaction. They will also show with the batch payment transaction in the bank reconciliation Find & Match screen. Depending on your individual bank, the detail may also show on the bank statement imported into Xero. Maximum field length = 18- Returns:
- details
-
setDetails
public void setDetails(String details)
(Non-NZ Only) These details are sent to the org’s bank as a reference for the batch payment transaction. They will also show with the batch payment transaction in the bank reconciliation Find & Match screen. Depending on your individual bank, the detail may also show on the bank statement imported into Xero. Maximum field length = 18- Parameters:
details- String
-
narrative
public BatchPayment narrative(String narrative)
(UK Only) Only shows on the statement line in Xero. Max length =18- Parameters:
narrative- String- Returns:
- BatchPayment
-
getNarrative
public String getNarrative()
(UK Only) Only shows on the statement line in Xero. Max length =18- Returns:
- narrative
-
setNarrative
public void setNarrative(String narrative)
(UK Only) Only shows on the statement line in Xero. Max length =18- Parameters:
narrative- String
-
getBatchPaymentID
public UUID getBatchPaymentID()
The Xero generated unique identifier for the bank transaction (read-only)- Returns:
- batchPaymentID
-
dateString
public BatchPayment dateString(String dateString)
Date the payment is being made (YYYY-MM-DD) e.g. 2009-09-06- Parameters:
dateString- String- Returns:
- BatchPayment
-
getDateString
public String getDateString()
Date the payment is being made (YYYY-MM-DD) e.g. 2009-09-06- Returns:
- dateString
-
setDateString
public void setDateString(String dateString)
Date the payment is being made (YYYY-MM-DD) e.g. 2009-09-06- Parameters:
dateString- String
-
date
public BatchPayment date(String date)
Date the payment is being made (YYYY-MM-DD) e.g. 2009-09-06- Parameters:
date- String- Returns:
- BatchPayment
-
getDate
public String getDate()
Date the payment is being made (YYYY-MM-DD) e.g. 2009-09-06- Returns:
- date
-
getDateAsDate
public org.threeten.bp.LocalDate getDateAsDate()
Date the payment is being made (YYYY-MM-DD) e.g. 2009-09-06- Returns:
- LocalDate
-
setDate
public void setDate(String date)
Date the payment is being made (YYYY-MM-DD) e.g. 2009-09-06- Parameters:
date- String
-
setDate
public void setDate(org.threeten.bp.LocalDate date)
Date the payment is being made (YYYY-MM-DD) e.g. 2009-09-06- Parameters:
date- LocalDateTime
-
amount
public BatchPayment amount(Double amount)
The amount of the payment. Must be less than or equal to the outstanding amount owing on the invoice e.g. 200.00- Parameters:
amount- Double- Returns:
- BatchPayment
-
getAmount
public Double 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
public void setAmount(Double amount)
The amount of the payment. Must be less than or equal to the outstanding amount owing on the invoice e.g. 200.00- Parameters:
amount- Double
-
payments
public BatchPayment payments(List<Payment> payments)
An array of payments- Parameters:
payments- List<Payment>- Returns:
- BatchPayment
-
addPaymentsItem
public BatchPayment addPaymentsItem(Payment paymentsItem)
An array of payments- Parameters:
paymentsItem- Payment- Returns:
- BatchPayment
-
setPayments
public void setPayments(List<Payment> payments)
An array of payments- Parameters:
payments- List<Payment>
-
getType
public BatchPayment.TypeEnum getType()
PAYBATCH for bill payments or RECBATCH for sales invoice payments (read-only)- Returns:
- type
-
getStatus
public BatchPayment.StatusEnum getStatus()
AUTHORISED or DELETED (read-only). New batch payments will have a status of AUTHORISED. It is not possible to delete batch payments via the API.- Returns:
- status
-
getTotalAmount
public String getTotalAmount()
The total of the payments that make up the batch (read-only)- Returns:
- totalAmount
-
getUpdatedDateUTC
public String getUpdatedDateUTC()
UTC timestamp of last update to the payment- Returns:
- updatedDateUTC
-
getUpdatedDateUTCAsDate
public org.threeten.bp.OffsetDateTime getUpdatedDateUTCAsDate()
UTC timestamp of last update to the payment- Returns:
- OffsetDateTime
-
getIsReconciled
public String getIsReconciled()
Booelan that tells you if the batch payment has been reconciled (read-only)- Returns:
- isReconciled
-
validationErrors
public BatchPayment validationErrors(List<ValidationError> validationErrors)
Displays array of validation error messages from the API- Parameters:
validationErrors- List<ValidationError>- Returns:
- BatchPayment
-
addValidationErrorsItem
public BatchPayment addValidationErrorsItem(ValidationError validationErrorsItem)
Displays array of validation error messages from the API- Parameters:
validationErrorsItem- ValidationError- Returns:
- BatchPayment
-
getValidationErrors
public List<ValidationError> getValidationErrors()
Displays array of validation error messages from the API- Returns:
- validationErrors
-
setValidationErrors
public void setValidationErrors(List<ValidationError> validationErrors)
Displays array of validation error messages from the API- Parameters:
validationErrors- List<ValidationError>
-
-