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

com.shell.apitest.models.ShellSiteRestriction Maven / Gradle / Ivy

/*
 * ShellCardManagementAPIsLib
 *
 * This file was automatically generated by APIMATIC v3.0 ( https://www.apimatic.io ).
 */

package com.shell.apitest.models;

import com.fasterxml.jackson.annotation.JsonGetter;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonSetter;
import java.util.List;

/**
 * This is a model class for ShellSiteRestriction type.
 */
public class ShellSiteRestriction {
    private String country;
    private List sites;
    private List siteGroups;
    private Boolean exclusive;

    /**
     * Default constructor.
     */
    public ShellSiteRestriction() {
    }

    /**
     * Initialization constructor.
     * @param  country  String value for country.
     * @param  sites  List of String value for sites.
     * @param  siteGroups  List of String value for siteGroups.
     * @param  exclusive  Boolean value for exclusive.
     */
    public ShellSiteRestriction(
            String country,
            List sites,
            List siteGroups,
            Boolean exclusive) {
        this.country = country;
        this.sites = sites;
        this.siteGroups = siteGroups;
        this.exclusive = exclusive;
    }

    /**
     * Getter for Country.
     * ISO 3166-1 Numeric-3 code of the country where the site restriction is applied. Example: 826
     * for United Kingdom.
     * @return Returns the String
     */
    @JsonGetter("Country")
    @JsonInclude(JsonInclude.Include.NON_NULL)
    public String getCountry() {
        return country;
    }

    /**
     * Setter for Country.
     * ISO 3166-1 Numeric-3 code of the country where the site restriction is applied. Example: 826
     * for United Kingdom.
     * @param country Value for String
     */
    @JsonSetter("Country")
    public void setCountry(String country) {
        this.country = country;
    }

    /**
     * Getter for Sites.
     * A list of Site IDs in this country, in the format “AA1111” where “AA” is a 2-character
     * country code and “1111” is a 4-digit site number in that country, which is either restricted
     * or allowed. For example, “GB1234”.
     * @return Returns the List of String
     */
    @JsonGetter("Sites")
    @JsonInclude(JsonInclude.Include.NON_NULL)
    public List getSites() {
        return sites;
    }

    /**
     * Setter for Sites.
     * A list of Site IDs in this country, in the format “AA1111” where “AA” is a 2-character
     * country code and “1111” is a 4-digit site number in that country, which is either restricted
     * or allowed. For example, “GB1234”.
     * @param sites Value for List of String
     */
    @JsonSetter("Sites")
    public void setSites(List sites) {
        this.sites = sites;
    }

    /**
     * Getter for SiteGroups.
     * A list of site group ids in this country which is either restricted or allowed.
     * @return Returns the List of String
     */
    @JsonGetter("SiteGroups")
    @JsonInclude(JsonInclude.Include.NON_NULL)
    public List getSiteGroups() {
        return siteGroups;
    }

    /**
     * Setter for SiteGroups.
     * A list of site group ids in this country which is either restricted or allowed.
     * @param siteGroups Value for List of String
     */
    @JsonSetter("SiteGroups")
    public void setSiteGroups(List siteGroups) {
        this.siteGroups = siteGroups;
    }

    /**
     * Getter for Exclusive.
     * Flag indicates whether the profile is inclusive or exclusive. Example: False - (inclusive),
     * i.e. the “Sites” & “SiteGroups” properties lists the sites & site groups where the
     * transaction will be allowed. True - (exclusive), i.e. the “Sites” & “SiteGroups” properties
     * lists the sites and site groups where the transactions will be declined.
     * @return Returns the Boolean
     */
    @JsonGetter("Exclusive")
    @JsonInclude(JsonInclude.Include.NON_NULL)
    public Boolean getExclusive() {
        return exclusive;
    }

    /**
     * Setter for Exclusive.
     * Flag indicates whether the profile is inclusive or exclusive. Example: False - (inclusive),
     * i.e. the “Sites” & “SiteGroups” properties lists the sites & site groups where the
     * transaction will be allowed. True - (exclusive), i.e. the “Sites” & “SiteGroups” properties
     * lists the sites and site groups where the transactions will be declined.
     * @param exclusive Value for Boolean
     */
    @JsonSetter("Exclusive")
    public void setExclusive(Boolean exclusive) {
        this.exclusive = exclusive;
    }

    /**
     * Converts this ShellSiteRestriction into string format.
     * @return String representation of this class
     */
    @Override
    public String toString() {
        return "ShellSiteRestriction [" + "country=" + country + ", sites=" + sites
                + ", siteGroups=" + siteGroups + ", exclusive=" + exclusive + "]";
    }

    /**
     * Builds a new {@link ShellSiteRestriction.Builder} object.
     * Creates the instance with the state of the current model.
     * @return a new {@link ShellSiteRestriction.Builder} object
     */
    public Builder toBuilder() {
        Builder builder = new Builder()
                .country(getCountry())
                .sites(getSites())
                .siteGroups(getSiteGroups())
                .exclusive(getExclusive());
        return builder;
    }

    /**
     * Class to build instances of {@link ShellSiteRestriction}.
     */
    public static class Builder {
        private String country;
        private List sites;
        private List siteGroups;
        private Boolean exclusive;



        /**
         * Setter for country.
         * @param  country  String value for country.
         * @return Builder
         */
        public Builder country(String country) {
            this.country = country;
            return this;
        }

        /**
         * Setter for sites.
         * @param  sites  List of String value for sites.
         * @return Builder
         */
        public Builder sites(List sites) {
            this.sites = sites;
            return this;
        }

        /**
         * Setter for siteGroups.
         * @param  siteGroups  List of String value for siteGroups.
         * @return Builder
         */
        public Builder siteGroups(List siteGroups) {
            this.siteGroups = siteGroups;
            return this;
        }

        /**
         * Setter for exclusive.
         * @param  exclusive  Boolean value for exclusive.
         * @return Builder
         */
        public Builder exclusive(Boolean exclusive) {
            this.exclusive = exclusive;
            return this;
        }

        /**
         * Builds a new {@link ShellSiteRestriction} object using the set fields.
         * @return {@link ShellSiteRestriction}
         */
        public ShellSiteRestriction build() {
            return new ShellSiteRestriction(country, sites, siteGroups, exclusive);
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy