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

com.adyen.model.management.ApiCredentialLinks Maven / Gradle / Ivy

There is a newer version: 38.1.0
Show newest version
/*
 * Management API
 *
 * The version of the OpenAPI document: 3
 * 
 *
 * 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.management;

import java.util.Objects;
import java.util.Map;
import java.util.HashMap;
import com.adyen.model.management.LinksElement;
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 java.util.Arrays;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.fasterxml.jackson.core.JsonProcessingException;


/**
 * ApiCredentialLinks
 */
@JsonPropertyOrder({
  ApiCredentialLinks.JSON_PROPERTY_ALLOWED_ORIGINS,
  ApiCredentialLinks.JSON_PROPERTY_COMPANY,
  ApiCredentialLinks.JSON_PROPERTY_GENERATE_API_KEY,
  ApiCredentialLinks.JSON_PROPERTY_GENERATE_CLIENT_KEY,
  ApiCredentialLinks.JSON_PROPERTY_MERCHANT,
  ApiCredentialLinks.JSON_PROPERTY_SELF
})

public class ApiCredentialLinks {
  public static final String JSON_PROPERTY_ALLOWED_ORIGINS = "allowedOrigins";
  private LinksElement allowedOrigins;

  public static final String JSON_PROPERTY_COMPANY = "company";
  private LinksElement company;

  public static final String JSON_PROPERTY_GENERATE_API_KEY = "generateApiKey";
  private LinksElement generateApiKey;

  public static final String JSON_PROPERTY_GENERATE_CLIENT_KEY = "generateClientKey";
  private LinksElement generateClientKey;

  public static final String JSON_PROPERTY_MERCHANT = "merchant";
  private LinksElement merchant;

  public static final String JSON_PROPERTY_SELF = "self";
  private LinksElement self;

  public ApiCredentialLinks() { 
  }

  /**
   * allowedOrigins
   *
   * @param allowedOrigins 
   * @return the current {@code ApiCredentialLinks} instance, allowing for method chaining
   */
  public ApiCredentialLinks allowedOrigins(LinksElement allowedOrigins) {
    this.allowedOrigins = allowedOrigins;
    return this;
  }

  /**
   * Get allowedOrigins
   * @return allowedOrigins 
   */
  @JsonProperty(JSON_PROPERTY_ALLOWED_ORIGINS)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public LinksElement getAllowedOrigins() {
    return allowedOrigins;
  }

  /**
   * allowedOrigins
   *
   * @param allowedOrigins 
   */
  @JsonProperty(JSON_PROPERTY_ALLOWED_ORIGINS)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setAllowedOrigins(LinksElement allowedOrigins) {
    this.allowedOrigins = allowedOrigins;
  }

  /**
   * company
   *
   * @param company 
   * @return the current {@code ApiCredentialLinks} instance, allowing for method chaining
   */
  public ApiCredentialLinks company(LinksElement company) {
    this.company = company;
    return this;
  }

  /**
   * Get company
   * @return company 
   */
  @JsonProperty(JSON_PROPERTY_COMPANY)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public LinksElement getCompany() {
    return company;
  }

  /**
   * company
   *
   * @param company 
   */
  @JsonProperty(JSON_PROPERTY_COMPANY)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setCompany(LinksElement company) {
    this.company = company;
  }

  /**
   * generateApiKey
   *
   * @param generateApiKey 
   * @return the current {@code ApiCredentialLinks} instance, allowing for method chaining
   */
  public ApiCredentialLinks generateApiKey(LinksElement generateApiKey) {
    this.generateApiKey = generateApiKey;
    return this;
  }

  /**
   * Get generateApiKey
   * @return generateApiKey 
   */
  @JsonProperty(JSON_PROPERTY_GENERATE_API_KEY)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public LinksElement getGenerateApiKey() {
    return generateApiKey;
  }

  /**
   * generateApiKey
   *
   * @param generateApiKey 
   */
  @JsonProperty(JSON_PROPERTY_GENERATE_API_KEY)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setGenerateApiKey(LinksElement generateApiKey) {
    this.generateApiKey = generateApiKey;
  }

  /**
   * generateClientKey
   *
   * @param generateClientKey 
   * @return the current {@code ApiCredentialLinks} instance, allowing for method chaining
   */
  public ApiCredentialLinks generateClientKey(LinksElement generateClientKey) {
    this.generateClientKey = generateClientKey;
    return this;
  }

  /**
   * Get generateClientKey
   * @return generateClientKey 
   */
  @JsonProperty(JSON_PROPERTY_GENERATE_CLIENT_KEY)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public LinksElement getGenerateClientKey() {
    return generateClientKey;
  }

  /**
   * generateClientKey
   *
   * @param generateClientKey 
   */
  @JsonProperty(JSON_PROPERTY_GENERATE_CLIENT_KEY)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setGenerateClientKey(LinksElement generateClientKey) {
    this.generateClientKey = generateClientKey;
  }

  /**
   * merchant
   *
   * @param merchant 
   * @return the current {@code ApiCredentialLinks} instance, allowing for method chaining
   */
  public ApiCredentialLinks merchant(LinksElement merchant) {
    this.merchant = merchant;
    return this;
  }

  /**
   * Get merchant
   * @return merchant 
   */
  @JsonProperty(JSON_PROPERTY_MERCHANT)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public LinksElement getMerchant() {
    return merchant;
  }

  /**
   * merchant
   *
   * @param merchant 
   */
  @JsonProperty(JSON_PROPERTY_MERCHANT)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setMerchant(LinksElement merchant) {
    this.merchant = merchant;
  }

  /**
   * self
   *
   * @param self 
   * @return the current {@code ApiCredentialLinks} instance, allowing for method chaining
   */
  public ApiCredentialLinks self(LinksElement self) {
    this.self = self;
    return this;
  }

  /**
   * Get self
   * @return self 
   */
  @JsonProperty(JSON_PROPERTY_SELF)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public LinksElement getSelf() {
    return self;
  }

  /**
   * self
   *
   * @param self 
   */
  @JsonProperty(JSON_PROPERTY_SELF)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setSelf(LinksElement self) {
    this.self = self;
  }

  /**
   * Return true if this ApiCredentialLinks object is equal to o.
   */
  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    ApiCredentialLinks apiCredentialLinks = (ApiCredentialLinks) o;
    return Objects.equals(this.allowedOrigins, apiCredentialLinks.allowedOrigins) &&
        Objects.equals(this.company, apiCredentialLinks.company) &&
        Objects.equals(this.generateApiKey, apiCredentialLinks.generateApiKey) &&
        Objects.equals(this.generateClientKey, apiCredentialLinks.generateClientKey) &&
        Objects.equals(this.merchant, apiCredentialLinks.merchant) &&
        Objects.equals(this.self, apiCredentialLinks.self);
  }

  @Override
  public int hashCode() {
    return Objects.hash(allowedOrigins, company, generateApiKey, generateClientKey, merchant, self);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class ApiCredentialLinks {\n");
    sb.append("    allowedOrigins: ").append(toIndentedString(allowedOrigins)).append("\n");
    sb.append("    company: ").append(toIndentedString(company)).append("\n");
    sb.append("    generateApiKey: ").append(toIndentedString(generateApiKey)).append("\n");
    sb.append("    generateClientKey: ").append(toIndentedString(generateClientKey)).append("\n");
    sb.append("    merchant: ").append(toIndentedString(merchant)).append("\n");
    sb.append("    self: ").append(toIndentedString(self)).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 ApiCredentialLinks given an JSON string
   *
   * @param jsonString JSON string
   * @return An instance of ApiCredentialLinks
   * @throws JsonProcessingException if the JSON string is invalid with respect to ApiCredentialLinks
   */
  public static ApiCredentialLinks fromJson(String jsonString) throws JsonProcessingException {
    return JSON.getMapper().readValue(jsonString, ApiCredentialLinks.class);
  }
/**
  * Convert an instance of ApiCredentialLinks to an JSON string
  *
  * @return JSON string
  */
  public String toJson() throws JsonProcessingException {
    return JSON.getMapper().writeValueAsString(this);
  }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy