Skip to content

Instantly share code, notes, and snippets.

@pedrovarela86
Created August 30, 2021 14:44
Show Gist options
  • Save pedrovarela86/5bc86b6b29ff0e013e4ac58ed337726b to your computer and use it in GitHub Desktop.
Save pedrovarela86/5bc86b6b29ff0e013e4ac58ed337726b to your computer and use it in GitHub Desktop.
//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//
package com.backbase.android.client.transactions.dto;
import android.os.Parcel;
import android.os.Parcelable.Creator;
import androidx.annotation.VisibleForTesting;
import com.backbase.android.client.transactions.dto.types.BillingStatus;
import com.backbase.android.client.transactions.dto.types.CreditDebitIndicator;
import com.backbase.android.client.transactions.dto.types.Type;
import com.backbase.android.client.transactions.dto.types.TypeGroup;
import com.backbase.android.common.utils.dto.Additions;
import com.backbase.android.common.utils.dto.Amount;
import java.util.Objects;
public class TransactionItem extends Additions {
private String id;
private String arrangementId;
private String externalId;
private String externalArrangementId;
private String productId;
private String reference;
private String description;
private TypeGroup typeGroup;
private Type type;
private String category;
private String bookingDate;
private String valueDate;
private Amount transactionAmountCurrency;
/** @deprecated */
@Deprecated
private Number amount;
/** @deprecated */
@Deprecated
private String currency;
private CreditDebitIndicator creditDebitIndicator;
private Amount instructedAmountCurrency;
/** @deprecated */
@Deprecated
private Number instructedAmount;
/** @deprecated */
@Deprecated
private String instructedCurrency;
private Number currencyExchangeRate;
private String counterPartyName;
private String counterPartyAccountNumber;
private String counterPartyBIC;
private String counterPartyCountry;
private String counterPartyBankName;
private String creditorId;
private String mandateReference;
private BillingStatus billingStatus;
private String notes;
private Number runningBalance;
private long checkSerialNumber;
public static final Creator<TransactionItem> CREATOR = new Creator<TransactionItem>() {
public TransactionItem createFromParcel(Parcel source) {
return new TransactionItem(source);
}
public TransactionItem[] newArray(int size) {
return new TransactionItem[size];
}
};
@VisibleForTesting
public TransactionItem() {
}
public TransactionItem(String id, String arrangementId, String description, TypeGroup typeGroup, Type type, String bookingDate, CreditDebitIndicator creditDebitIndicator) {
this.id = id;
this.arrangementId = arrangementId;
this.description = description;
this.typeGroup = typeGroup;
this.type = type;
this.bookingDate = bookingDate;
this.creditDebitIndicator = creditDebitIndicator;
}
/** @deprecated */
@Deprecated
public TransactionItem(String id, String arrangementId, String externalArrangementId, String productId, String reference, String description, TypeGroup typeGroup, Type type, String bookingDate, Number amount, String currency, CreditDebitIndicator creditDebitIndicator, String counterPartyName, String imageType) {
this.id = id;
this.arrangementId = arrangementId;
this.externalArrangementId = externalArrangementId;
this.productId = productId;
this.reference = reference;
this.description = description;
this.typeGroup = typeGroup;
this.type = type;
this.bookingDate = bookingDate;
this.amount = amount;
this.currency = currency;
this.creditDebitIndicator = creditDebitIndicator;
this.counterPartyName = counterPartyName;
}
protected TransactionItem(Parcel in) {
super(in);
this.id = in.readString();
this.arrangementId = in.readString();
this.externalId = in.readString();
this.externalArrangementId = in.readString();
this.productId = in.readString();
this.reference = in.readString();
this.description = in.readString();
int tmpTypeGroup = in.readInt();
this.typeGroup = tmpTypeGroup == -1 ? null : TypeGroup.values()[tmpTypeGroup];
int tmpType = in.readInt();
this.type = tmpType == -1 ? null : Type.values()[tmpType];
this.category = in.readString();
this.bookingDate = in.readString();
this.valueDate = in.readString();
this.transactionAmountCurrency = (Amount)in.readParcelable(Amount.class.getClassLoader());
this.amount = (Number)in.readSerializable();
this.currency = in.readString();
int tmpCreditDebitIndicator = in.readInt();
this.creditDebitIndicator = tmpCreditDebitIndicator == -1 ? null : CreditDebitIndicator.values()[tmpCreditDebitIndicator];
this.instructedAmountCurrency = (Amount)in.readParcelable(Amount.class.getClassLoader());
this.instructedAmount = (Number)in.readSerializable();
this.instructedCurrency = in.readString();
this.currencyExchangeRate = (Number)in.readSerializable();
this.counterPartyName = in.readString();
this.counterPartyAccountNumber = in.readString();
this.counterPartyBIC = in.readString();
this.counterPartyCountry = in.readString();
this.counterPartyBankName = in.readString();
this.creditorId = in.readString();
this.mandateReference = in.readString();
int tmpBillingStatus = in.readInt();
this.billingStatus = tmpBillingStatus == -1 ? null : BillingStatus.values()[tmpBillingStatus];
this.notes = in.readString();
this.runningBalance = (Number)in.readSerializable();
this.checkSerialNumber = in.readLong();
}
public String getId() {
return this.id;
}
public void setId(String id) {
this.id = id;
}
public String getArrangementId() {
return this.arrangementId;
}
public void setArrangementId(String arrangementId) {
this.arrangementId = arrangementId;
}
public String getExternalId() {
return this.externalId;
}
public void setExternalId(String externalId) {
this.externalId = externalId;
}
public String getExternalArrangementId() {
return this.externalArrangementId;
}
public void setExternalArrangementId(String externalArrangementId) {
this.externalArrangementId = externalArrangementId;
}
public String getProductId() {
return this.productId;
}
public void setProductId(String productId) {
this.productId = productId;
}
public String getReference() {
return this.reference;
}
public void setReference(String reference) {
this.reference = reference;
}
public String getDescription() {
return this.description;
}
public void setDescription(String description) {
this.description = description;
}
public TypeGroup getTypeGroup() {
return this.typeGroup;
}
public void setTypeGroup(TypeGroup typeGroup) {
this.typeGroup = typeGroup;
}
public Type getType() {
return this.type;
}
public void setType(Type type) {
this.type = type;
}
public String getCategory() {
return this.category;
}
public void setCategory(String category) {
this.category = category;
}
public String getBookingDate() {
return this.bookingDate;
}
public void setBookingDate(String bookingDate) {
this.bookingDate = bookingDate;
}
public String getValueDate() {
return this.valueDate;
}
public void setValueDate(String valueDate) {
this.valueDate = valueDate;
}
public Amount getTransactionAmountCurrency() {
return this.transactionAmountCurrency;
}
public void setTransactionAmountCurrency(Amount transactionAmountCurrency) {
this.transactionAmountCurrency = transactionAmountCurrency;
}
/** @deprecated */
@Deprecated
public Number getAmount() {
return this.amount;
}
/** @deprecated */
@Deprecated
public void setAmount(Number amount) {
this.amount = amount;
}
/** @deprecated */
@Deprecated
public String getCurrency() {
return this.currency;
}
/** @deprecated */
@Deprecated
public void setCurrency(String currency) {
this.currency = currency;
}
public CreditDebitIndicator getCreditDebitIndicator() {
return this.creditDebitIndicator;
}
public void setCreditDebitIndicator(CreditDebitIndicator creditDebitIndicator) {
this.creditDebitIndicator = creditDebitIndicator;
}
public Amount getInstructedAmountCurrency() {
return this.instructedAmountCurrency;
}
public void setInstructedAmountCurrency(Amount instructedAmountCurrency) {
this.instructedAmountCurrency = instructedAmountCurrency;
}
/** @deprecated */
@Deprecated
public Number getInstructedAmount() {
return this.instructedAmount;
}
/** @deprecated */
@Deprecated
public void setInstructedAmount(Number instructedAmount) {
this.instructedAmount = instructedAmount;
}
/** @deprecated */
@Deprecated
public String getInstructedCurrency() {
return this.instructedCurrency;
}
/** @deprecated */
@Deprecated
public void setInstructedCurrency(String instructedCurrency) {
this.instructedCurrency = instructedCurrency;
}
public Number getCurrencyExchangeRate() {
return this.currencyExchangeRate;
}
public void setCurrencyExchangeRate(Number currencyExchangeRate) {
this.currencyExchangeRate = currencyExchangeRate;
}
public String getCounterPartyName() {
return this.counterPartyName;
}
public void setCounterPartyName(String counterPartyName) {
this.counterPartyName = counterPartyName;
}
public String getCounterPartyAccountNumber() {
return this.counterPartyAccountNumber;
}
public void setCounterPartyAccountNumber(String counterPartyAccountNumber) {
this.counterPartyAccountNumber = counterPartyAccountNumber;
}
public String getCounterPartyBIC() {
return this.counterPartyBIC;
}
public void setCounterPartyBIC(String counterPartyBIC) {
this.counterPartyBIC = counterPartyBIC;
}
public String getCounterPartyCountry() {
return this.counterPartyCountry;
}
public void setCounterPartyCountry(String counterPartyCountry) {
this.counterPartyCountry = counterPartyCountry;
}
public String getCounterPartyBankName() {
return this.counterPartyBankName;
}
public void setCounterPartyBankName(String counterPartyBankName) {
this.counterPartyBankName = counterPartyBankName;
}
public String getCreditorId() {
return this.creditorId;
}
public void setCreditorId(String creditorId) {
this.creditorId = creditorId;
}
public String getMandateReference() {
return this.mandateReference;
}
public void setMandateReference(String mandateReference) {
this.mandateReference = mandateReference;
}
public BillingStatus getBillingStatus() {
return this.billingStatus;
}
public void setBillingStatus(BillingStatus billingStatus) {
this.billingStatus = billingStatus;
}
public void setNotes(String notes) {
this.notes = notes;
}
public String getNotes() {
return this.notes;
}
public int describeContents() {
return 0;
}
public void setCheckSerialNumber(String checkSerialNumber) {
this.checkSerialNumber = Long.parseLong(checkSerialNumber);
}
public String getCheckSerialNumber() {
return String.valueOf(this.checkSerialNumber);
}
public void setRunningBalance(Number runningBalance) {
this.runningBalance = runningBalance;
}
public Number getRunningBalance() {
return this.runningBalance;
}
public void writeToParcel(Parcel dest, int flags) {
super.writeToParcel(dest, flags);
dest.writeString(this.id);
dest.writeString(this.arrangementId);
dest.writeString(this.externalId);
dest.writeString(this.externalArrangementId);
dest.writeString(this.productId);
dest.writeString(this.reference);
dest.writeString(this.description);
dest.writeInt(this.typeGroup == null ? -1 : this.typeGroup.ordinal());
dest.writeInt(this.type == null ? -1 : this.type.ordinal());
dest.writeString(this.category);
dest.writeString(this.bookingDate);
dest.writeString(this.valueDate);
dest.writeParcelable(this.transactionAmountCurrency, flags);
dest.writeSerializable(this.amount);
dest.writeString(this.currency);
dest.writeInt(this.creditDebitIndicator == null ? -1 : this.creditDebitIndicator.ordinal());
dest.writeParcelable(this.instructedAmountCurrency, flags);
dest.writeSerializable(this.instructedAmount);
dest.writeString(this.instructedCurrency);
dest.writeSerializable(this.currencyExchangeRate);
dest.writeString(this.counterPartyName);
dest.writeString(this.counterPartyAccountNumber);
dest.writeString(this.counterPartyBIC);
dest.writeString(this.counterPartyCountry);
dest.writeString(this.counterPartyBankName);
dest.writeString(this.creditorId);
dest.writeString(this.mandateReference);
dest.writeInt(this.billingStatus == null ? -1 : this.billingStatus.ordinal());
dest.writeString(this.notes);
dest.writeSerializable(this.runningBalance);
dest.writeLong(this.checkSerialNumber);
}
public boolean equals(Object o) {
if (this == o) {
return true;
} else if (!(o instanceof TransactionItem)) {
return false;
} else if (!super.equals(o)) {
return false;
} else {
TransactionItem that = (TransactionItem)o;
return this.checkSerialNumber == that.checkSerialNumber && Objects.equals(this.id, that.id) && Objects.equals(this.arrangementId, that.arrangementId) && Objects.equals(this.externalId, that.externalId) && Objects.equals(this.externalArrangementId, that.externalArrangementId) && Objects.equals(this.productId, that.productId) && Objects.equals(this.reference, that.reference) && Objects.equals(this.description, that.description) && this.typeGroup == that.typeGroup && this.type == that.type && Objects.equals(this.category, that.category) && Objects.equals(this.bookingDate, that.bookingDate) && Objects.equals(this.valueDate, that.valueDate) && Objects.equals(this.transactionAmountCurrency, that.transactionAmountCurrency) && Objects.equals(this.amount, that.amount) && Objects.equals(this.currency, that.currency) && this.creditDebitIndicator == that.creditDebitIndicator && Objects.equals(this.instructedAmountCurrency, that.instructedAmountCurrency) && Objects.equals(this.instructedAmount, that.instructedAmount) && Objects.equals(this.instructedCurrency, that.instructedCurrency) && Objects.equals(this.currencyExchangeRate, that.currencyExchangeRate) && Objects.equals(this.counterPartyName, that.counterPartyName) && Objects.equals(this.counterPartyAccountNumber, that.counterPartyAccountNumber) && Objects.equals(this.counterPartyBIC, that.counterPartyBIC) && Objects.equals(this.counterPartyCountry, that.counterPartyCountry) && Objects.equals(this.counterPartyBankName, that.counterPartyBankName) && Objects.equals(this.creditorId, that.creditorId) && Objects.equals(this.mandateReference, that.mandateReference) && this.billingStatus == that.billingStatus && Objects.equals(this.notes, that.notes) && Objects.equals(this.runningBalance, that.runningBalance);
}
}
public int hashCode() {
return Objects.hash(new Object[]{super.hashCode(), this.id, this.arrangementId, this.externalId, this.externalArrangementId, this.productId, this.reference, this.description, this.typeGroup, this.type, this.category, this.bookingDate, this.valueDate, this.transactionAmountCurrency, this.amount, this.currency, this.creditDebitIndicator, this.instructedAmountCurrency, this.instructedAmount, this.instructedCurrency, this.currencyExchangeRate, this.counterPartyName, this.counterPartyAccountNumber, this.counterPartyBIC, this.counterPartyCountry, this.counterPartyBankName, this.creditorId, this.mandateReference, this.billingStatus, this.notes, this.runningBalance, this.checkSerialNumber});
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment