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

com.adyen.model.marketpaywebhooks.AccountPayoutState Maven / Gradle / Ivy

There is a newer version: 38.1.0
Show newest version
/*
 * Classic Platforms - Notifications
 *
 * The version of the OpenAPI document: 6
 * 
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */


package com.adyen.model.marketpaywebhooks;

import java.util.Objects;
import java.util.Arrays;
import java.util.Map;
import java.util.HashMap;
import com.adyen.model.marketpaywebhooks.Amount;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonTypeName;
import com.fasterxml.jackson.annotation.JsonValue;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.fasterxml.jackson.core.JsonProcessingException;


/**
 * AccountPayoutState
 */
@JsonPropertyOrder({
  AccountPayoutState.JSON_PROPERTY_ALLOW_PAYOUT,
  AccountPayoutState.JSON_PROPERTY_DISABLE_REASON,
  AccountPayoutState.JSON_PROPERTY_DISABLED,
  AccountPayoutState.JSON_PROPERTY_NOT_ALLOWED_REASON,
  AccountPayoutState.JSON_PROPERTY_PAYOUT_LIMIT,
  AccountPayoutState.JSON_PROPERTY_TIER_NUMBER
})

public class AccountPayoutState {
  public static final String JSON_PROPERTY_ALLOW_PAYOUT = "allowPayout";
  private Boolean allowPayout;

  public static final String JSON_PROPERTY_DISABLE_REASON = "disableReason";
  private String disableReason;

  public static final String JSON_PROPERTY_DISABLED = "disabled";
  private Boolean disabled;

  public static final String JSON_PROPERTY_NOT_ALLOWED_REASON = "notAllowedReason";
  private String notAllowedReason;

  public static final String JSON_PROPERTY_PAYOUT_LIMIT = "payoutLimit";
  private Amount payoutLimit;

  public static final String JSON_PROPERTY_TIER_NUMBER = "tierNumber";
  private Integer tierNumber;

  public AccountPayoutState() { 
  }

  public AccountPayoutState allowPayout(Boolean allowPayout) {
    this.allowPayout = allowPayout;
    return this;
  }

   /**
   * Indicates whether payouts are allowed. This field is the overarching payout status, and is the aggregate of multiple conditions (e.g., KYC status, disabled flag, etc). If this field is false, no payouts will be permitted for any of the account holder's accounts. If this field is true, payouts will be permitted for any of the account holder's accounts.
   * @return allowPayout
  **/
  @ApiModelProperty(value = "Indicates whether payouts are allowed. This field is the overarching payout status, and is the aggregate of multiple conditions (e.g., KYC status, disabled flag, etc). If this field is false, no payouts will be permitted for any of the account holder's accounts. If this field is true, payouts will be permitted for any of the account holder's accounts.")
  @JsonProperty(JSON_PROPERTY_ALLOW_PAYOUT)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public Boolean getAllowPayout() {
    return allowPayout;
  }


  @JsonProperty(JSON_PROPERTY_ALLOW_PAYOUT)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setAllowPayout(Boolean allowPayout) {
    this.allowPayout = allowPayout;
  }


  public AccountPayoutState disableReason(String disableReason) {
    this.disableReason = disableReason;
    return this;
  }

   /**
   * The reason why payouts (to all of the account holder's accounts) have been disabled (by the platform). If the `disabled` field is true, this field can be used to explain why.
   * @return disableReason
  **/
  @ApiModelProperty(value = "The reason why payouts (to all of the account holder's accounts) have been disabled (by the platform). If the `disabled` field is true, this field can be used to explain why.")
  @JsonProperty(JSON_PROPERTY_DISABLE_REASON)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public String getDisableReason() {
    return disableReason;
  }


  @JsonProperty(JSON_PROPERTY_DISABLE_REASON)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setDisableReason(String disableReason) {
    this.disableReason = disableReason;
  }


  public AccountPayoutState disabled(Boolean disabled) {
    this.disabled = disabled;
    return this;
  }

   /**
   * Indicates whether payouts have been disabled (by the platform) for all of the account holder's accounts. A platform may enable and disable this field at their discretion. If this field is true, `allowPayout` will be false and no payouts will be permitted for any of the account holder's accounts. If this field is false, `allowPayout` may or may not be enabled, depending on other factors.
   * @return disabled
  **/
  @ApiModelProperty(value = "Indicates whether payouts have been disabled (by the platform) for all of the account holder's accounts. A platform may enable and disable this field at their discretion. If this field is true, `allowPayout` will be false and no payouts will be permitted for any of the account holder's accounts. If this field is false, `allowPayout` may or may not be enabled, depending on other factors.")
  @JsonProperty(JSON_PROPERTY_DISABLED)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public Boolean getDisabled() {
    return disabled;
  }


  @JsonProperty(JSON_PROPERTY_DISABLED)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setDisabled(Boolean disabled) {
    this.disabled = disabled;
  }


  public AccountPayoutState notAllowedReason(String notAllowedReason) {
    this.notAllowedReason = notAllowedReason;
    return this;
  }

   /**
   * The reason why payouts (to all of the account holder's accounts) have been disabled (by Adyen). If payouts have been disabled by Adyen, this field will explain why. If this field is blank, payouts have not been disabled by Adyen.
   * @return notAllowedReason
  **/
  @ApiModelProperty(value = "The reason why payouts (to all of the account holder's accounts) have been disabled (by Adyen). If payouts have been disabled by Adyen, this field will explain why. If this field is blank, payouts have not been disabled by Adyen.")
  @JsonProperty(JSON_PROPERTY_NOT_ALLOWED_REASON)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public String getNotAllowedReason() {
    return notAllowedReason;
  }


  @JsonProperty(JSON_PROPERTY_NOT_ALLOWED_REASON)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setNotAllowedReason(String notAllowedReason) {
    this.notAllowedReason = notAllowedReason;
  }


  public AccountPayoutState payoutLimit(Amount payoutLimit) {
    this.payoutLimit = payoutLimit;
    return this;
  }

   /**
   * Get payoutLimit
   * @return payoutLimit
  **/
  @ApiModelProperty(value = "")
  @JsonProperty(JSON_PROPERTY_PAYOUT_LIMIT)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public Amount getPayoutLimit() {
    return payoutLimit;
  }


  @JsonProperty(JSON_PROPERTY_PAYOUT_LIMIT)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setPayoutLimit(Amount payoutLimit) {
    this.payoutLimit = payoutLimit;
  }


  public AccountPayoutState tierNumber(Integer tierNumber) {
    this.tierNumber = tierNumber;
    return this;
  }

   /**
   * The payout tier that the account holder occupies.
   * @return tierNumber
  **/
  @ApiModelProperty(value = "The payout tier that the account holder occupies.")
  @JsonProperty(JSON_PROPERTY_TIER_NUMBER)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public Integer getTierNumber() {
    return tierNumber;
  }


  @JsonProperty(JSON_PROPERTY_TIER_NUMBER)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setTierNumber(Integer tierNumber) {
    this.tierNumber = tierNumber;
  }


  /**
   * Return true if this AccountPayoutState object is equal to o.
   */
  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    AccountPayoutState accountPayoutState = (AccountPayoutState) o;
    return Objects.equals(this.allowPayout, accountPayoutState.allowPayout) &&
        Objects.equals(this.disableReason, accountPayoutState.disableReason) &&
        Objects.equals(this.disabled, accountPayoutState.disabled) &&
        Objects.equals(this.notAllowedReason, accountPayoutState.notAllowedReason) &&
        Objects.equals(this.payoutLimit, accountPayoutState.payoutLimit) &&
        Objects.equals(this.tierNumber, accountPayoutState.tierNumber);
  }

  @Override
  public int hashCode() {
    return Objects.hash(allowPayout, disableReason, disabled, notAllowedReason, payoutLimit, tierNumber);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class AccountPayoutState {\n");
    sb.append("    allowPayout: ").append(toIndentedString(allowPayout)).append("\n");
    sb.append("    disableReason: ").append(toIndentedString(disableReason)).append("\n");
    sb.append("    disabled: ").append(toIndentedString(disabled)).append("\n");
    sb.append("    notAllowedReason: ").append(toIndentedString(notAllowedReason)).append("\n");
    sb.append("    payoutLimit: ").append(toIndentedString(payoutLimit)).append("\n");
    sb.append("    tierNumber: ").append(toIndentedString(tierNumber)).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    ");
  }

/**
   * Create an instance of AccountPayoutState given an JSON string
   *
   * @param jsonString JSON string
   * @return An instance of AccountPayoutState
   * @throws JsonProcessingException if the JSON string is invalid with respect to AccountPayoutState
   */
  public static AccountPayoutState fromJson(String jsonString) throws JsonProcessingException {
    return JSON.getMapper().readValue(jsonString, AccountPayoutState.class);
  }
/**
  * Convert an instance of AccountPayoutState to an JSON string
  *
  * @return JSON string
  */
  public String toJson() throws JsonProcessingException {
    return JSON.getMapper().writeValueAsString(this);
  }
}





© 2015 - 2025 Weber Informatics LLC | Privacy Policy