All Downloads are FREE. Search and download functionalities are using the official Maven repository.

uk.org.openbanking.datamodel.account.Overdraft1OverdraftTierBandSet Maven / Gradle / Ivy

Go to download

A Java SDK to help implementing the Open Banking standard : https://www.openbanking.org.uk/read-write-apis/

There is a newer version: 3.1.2.5
Show newest version
/**
 *
 * The contents of this file are subject to the terms of the Common Development and
 *  Distribution License (the License). You may not use this file except in compliance with the
 *  License.
 *
 *  You can obtain a copy of the License at https://forgerock.org/cddlv1-0/. See the License for the
 *  specific language governing permission and limitations under the License.
 *
 *  When distributing Covered Software, include this CDDL Header Notice in each file and include
 *  the License file at legal/CDDLv1.0.txt. If applicable, add the following below the CDDL
 *  Header, with the fields enclosed by brackets [] replaced by your own identifying
 *  information: "Portions copyright [year] [name of copyright owner]".
 *
 *  Copyright 2019 ForgeRock AS.
 */
/*
 * Account and Transaction API Specification
 * Swagger for Account and Transaction API Specification
 *
 * OpenAPI spec version: v3.1.1
 * Contact: [email protected]
 *
 * NOTE: This class is auto generated by the swagger code generator program.
 * https://github.com/swagger-api/swagger-codegen.git
 * Do not edit the class manually.
 */


package uk.org.openbanking.datamodel.account;

import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonValue;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import javax.validation.Valid;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import javax.validation.constraints.Size;
import java.util.ArrayList;
import java.util.List;
import java.util.Objects;

/**
 * Tier band set details
 */
@ApiModel(description = "Tier band set details")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-05-23T11:27:41.089+01:00")
public class Overdraft1OverdraftTierBandSet {
    @JsonProperty("TierBandMethod")
    private TierBandMethodEnum tierBandMethod = null;
    @JsonProperty("OverdraftType")
    private OverdraftTypeEnum overdraftType = null;
    @JsonProperty("Identification")
    private String identification = null;
    @JsonProperty("AuthorisedIndicator")
    private Boolean authorisedIndicator = null;
    @JsonProperty("BufferAmount")
    private String bufferAmount = null;
    @JsonProperty("Notes")
    private List notes = null;
    @JsonProperty("OverdraftTierBand")
    private List overdraftTierBand = new ArrayList();
    @JsonProperty("OverdraftFeesCharges")
    private List overdraftFeesCharges = null;

    public Overdraft1OverdraftTierBandSet tierBandMethod(TierBandMethodEnum tierBandMethod) {
        this.tierBandMethod = tierBandMethod;
        return this;
    }

    /**
     * The methodology of how overdraft is charged. It can be: 'Whole'  Where the same charge/rate is applied to the entirety of the overdraft balance (where charges are applicable).  'Tiered' Where different charges/rates are applied dependent on overdraft maximum and minimum balance amount tiers defined by the lending financial organisation 'Banded' Where different charges/rates are applied dependent on overdraft maximum and minimum balance amount bands defined by a government organisation.
     *
     * @return tierBandMethod
     **/
    @NotNull
    @ApiModelProperty(required = true, value = "The methodology of how overdraft is charged. It can be: 'Whole'  Where the same charge/rate is applied to the entirety of the overdraft balance (where charges are applicable).  'Tiered' Where different charges/rates are applied dependent on overdraft maximum and minimum balance amount tiers defined by the lending financial organisation 'Banded' Where different charges/rates are applied dependent on overdraft maximum and minimum balance amount bands defined by a government organisation.")
    public TierBandMethodEnum getTierBandMethod() {
        return tierBandMethod;
    }

    public void setTierBandMethod(TierBandMethodEnum tierBandMethod) {
        this.tierBandMethod = tierBandMethod;
    }

    public Overdraft1OverdraftTierBandSet overdraftType(OverdraftTypeEnum overdraftType) {
        this.overdraftType = overdraftType;
        return this;
    }

    /**
     * An overdraft can either be 'committed' which means that the facility cannot be withdrawn without reasonable notification before it's agreed end date, or 'on demand' which means that the financial institution can demand repayment at any point in time.
     *
     * @return overdraftType
     **/
    @ApiModelProperty(value = "An overdraft can either be 'committed' which means that the facility cannot be withdrawn without reasonable notification before it's agreed end date, or 'on demand' which means that the financial institution can demand repayment at any point in time.")
    public OverdraftTypeEnum getOverdraftType() {
        return overdraftType;
    }

    public void setOverdraftType(OverdraftTypeEnum overdraftType) {
        this.overdraftType = overdraftType;
    }

    public Overdraft1OverdraftTierBandSet identification(String identification) {
        this.identification = identification;
        return this;
    }

    /**
     * Unique and unambiguous identification of a  Tier Band for a overdraft product.
     *
     * @return identification
     **/
    @Size(min = 1, max = 35)
    @ApiModelProperty(value = "Unique and unambiguous identification of a  Tier Band for a overdraft product.")
    public String getIdentification() {
        return identification;
    }

    public void setIdentification(String identification) {
        this.identification = identification;
    }

    public Overdraft1OverdraftTierBandSet authorisedIndicator(Boolean authorisedIndicator) {
        this.authorisedIndicator = authorisedIndicator;
        return this;
    }

    /**
     * Indicates if the Overdraft is authorised (Y) or unauthorised (N)
     *
     * @return authorisedIndicator
     **/
    @ApiModelProperty(value = "Indicates if the Overdraft is authorised (Y) or unauthorised (N)")
    public Boolean isAuthorisedIndicator() {
        return authorisedIndicator;
    }

    public void setAuthorisedIndicator(Boolean authorisedIndicator) {
        this.authorisedIndicator = authorisedIndicator;
    }

    public Overdraft1OverdraftTierBandSet bufferAmount(String bufferAmount) {
        this.bufferAmount = bufferAmount;
        return this;
    }

    /**
     * When a customer exceeds their credit limit, a financial institution will not charge the customer unauthorised overdraft charges if they do not exceed by more than the buffer amount. Note: Authorised overdraft charges may still apply.
     *
     * @return bufferAmount
     **/
    @Pattern(regexp = "^(-?\\d{1,14}){1}(\\.\\d{1,4}){0,1}$")
    @ApiModelProperty(value = "When a customer exceeds their credit limit, a financial institution will not charge the customer unauthorised overdraft charges if they do not exceed by more than the buffer amount. Note: Authorised overdraft charges may still apply.")
    public String getBufferAmount() {
        return bufferAmount;
    }

    public void setBufferAmount(String bufferAmount) {
        this.bufferAmount = bufferAmount;
    }

    public Overdraft1OverdraftTierBandSet notes(List notes) {
        this.notes = notes;
        return this;
    }

    public Overdraft1OverdraftTierBandSet addNotesItem(String notesItem) {
        if (this.notes == null) {
            this.notes = new ArrayList();
        }
        this.notes.add(notesItem);
        return this;
    }

    /**
     * Optional additional notes to supplement the overdraft Tier Band Set details
     *
     * @return notes
     **/
    @ApiModelProperty(value = "Optional additional notes to supplement the overdraft Tier Band Set details")
    public List getNotes() {
        return notes;
    }

    public void setNotes(List notes) {
        this.notes = notes;
    }

    public Overdraft1OverdraftTierBandSet overdraftTierBand(List overdraftTierBand) {
        this.overdraftTierBand = overdraftTierBand;
        return this;
    }

    public Overdraft1OverdraftTierBandSet addOverdraftTierBandItem(Overdraft1OverdraftTierBand overdraftTierBandItem) {
        this.overdraftTierBand.add(overdraftTierBandItem);
        return this;
    }

    /**
     * Provides overdraft details for a specific tier or band
     *
     * @return overdraftTierBand
     **/
    @NotNull
    @Valid
    @Size(min = 1)
    @ApiModelProperty(required = true, value = "Provides overdraft details for a specific tier or band")
    public List getOverdraftTierBand() {
        return overdraftTierBand;
    }

    public void setOverdraftTierBand(List overdraftTierBand) {
        this.overdraftTierBand = overdraftTierBand;
    }

    public Overdraft1OverdraftTierBandSet overdraftFeesCharges(List overdraftFeesCharges) {
        this.overdraftFeesCharges = overdraftFeesCharges;
        return this;
    }

    public Overdraft1OverdraftTierBandSet addOverdraftFeesChargesItem(Overdraft1OverdraftFeesCharges1 overdraftFeesChargesItem) {
        if (this.overdraftFeesCharges == null) {
            this.overdraftFeesCharges = new ArrayList();
        }
        this.overdraftFeesCharges.add(overdraftFeesChargesItem);
        return this;
    }

    /**
     * Overdraft fees and charges details
     *
     * @return overdraftFeesCharges
     **/
    @Valid
    @ApiModelProperty(value = "Overdraft fees and charges details")
    public List getOverdraftFeesCharges() {
        return overdraftFeesCharges;
    }

    public void setOverdraftFeesCharges(List overdraftFeesCharges) {
        this.overdraftFeesCharges = overdraftFeesCharges;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }
        if (o == null || getClass() != o.getClass()) {
            return false;
        }
        Overdraft1OverdraftTierBandSet overdraft1OverdraftTierBandSet = (Overdraft1OverdraftTierBandSet) o;
        return Objects.equals(this.tierBandMethod, overdraft1OverdraftTierBandSet.tierBandMethod) &&
                Objects.equals(this.overdraftType, overdraft1OverdraftTierBandSet.overdraftType) &&
                Objects.equals(this.identification, overdraft1OverdraftTierBandSet.identification) &&
                Objects.equals(this.authorisedIndicator, overdraft1OverdraftTierBandSet.authorisedIndicator) &&
                Objects.equals(this.bufferAmount, overdraft1OverdraftTierBandSet.bufferAmount) &&
                Objects.equals(this.notes, overdraft1OverdraftTierBandSet.notes) &&
                Objects.equals(this.overdraftTierBand, overdraft1OverdraftTierBandSet.overdraftTierBand) &&
                Objects.equals(this.overdraftFeesCharges, overdraft1OverdraftTierBandSet.overdraftFeesCharges);
    }

    @Override
    public int hashCode() {
        return Objects.hash(tierBandMethod, overdraftType, identification, authorisedIndicator, bufferAmount, notes, overdraftTierBand, overdraftFeesCharges);
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append("class Overdraft1OverdraftTierBandSet {\n");

        sb.append("    tierBandMethod: ").append(toIndentedString(tierBandMethod)).append("\n");
        sb.append("    overdraftType: ").append(toIndentedString(overdraftType)).append("\n");
        sb.append("    identification: ").append(toIndentedString(identification)).append("\n");
        sb.append("    authorisedIndicator: ").append(toIndentedString(authorisedIndicator)).append("\n");
        sb.append("    bufferAmount: ").append(toIndentedString(bufferAmount)).append("\n");
        sb.append("    notes: ").append(toIndentedString(notes)).append("\n");
        sb.append("    overdraftTierBand: ").append(toIndentedString(overdraftTierBand)).append("\n");
        sb.append("    overdraftFeesCharges: ").append(toIndentedString(overdraftFeesCharges)).append("\n");
        sb.append("}");
        return sb.toString();
    }

    /**
     * Convert the given object to string with each line indented by 4 spaces
     * (except the first line).
     */
    private String toIndentedString(Object o) {
        if (o == null) {
            return "null";
        }
        return o.toString().replace("\n", "\n    ");
    }


    /**
     * The methodology of how overdraft is charged. It can be: 'Whole'  Where the same charge/rate is applied to the entirety of the overdraft balance (where charges are applicable).  'Tiered' Where different charges/rates are applied dependent on overdraft maximum and minimum balance amount tiers defined by the lending financial organisation 'Banded' Where different charges/rates are applied dependent on overdraft maximum and minimum balance amount bands defined by a government organisation.
     */
    public enum TierBandMethodEnum {
        TIERED("Tiered"),

        WHOLE("Whole"),

        BANDED("Banded");

        private String value;

        TierBandMethodEnum(String value) {
            this.value = value;
        }

        @JsonCreator
        public static TierBandMethodEnum fromValue(String text) {
            for (TierBandMethodEnum b : TierBandMethodEnum.values()) {
                if (String.valueOf(b.value).equals(text)) {
                    return b;
                }
            }
            return null;
        }

        @JsonValue
        public String getValue() {
            return value;
        }

        @Override
        public String toString() {
            return String.valueOf(value);
        }
    }

    /**
     * An overdraft can either be 'committed' which means that the facility cannot be withdrawn without reasonable notification before it's agreed end date, or 'on demand' which means that the financial institution can demand repayment at any point in time.
     */
    public enum OverdraftTypeEnum {
        COMMITTED("Committed"),

        ONDEMAND("OnDemand"),

        OTHER("Other");

        private String value;

        OverdraftTypeEnum(String value) {
            this.value = value;
        }

        @JsonCreator
        public static OverdraftTypeEnum fromValue(String text) {
            for (OverdraftTypeEnum b : OverdraftTypeEnum.values()) {
                if (String.valueOf(b.value).equals(text)) {
                    return b;
                }
            }
            return null;
        }

        @JsonValue
        public String getValue() {
            return value;
        }

        @Override
        public String toString() {
            return String.valueOf(value);
        }
    }

}





© 2015 - 2024 Weber Informatics LLC | Privacy Policy