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

com.akeyless.auth.swagger.model.PolicyRules Maven / Gradle / Ivy

There is a newer version: 1.0.7
Show newest version
/*
 * Auth - Application API
 * Auth manages access policies for services that need access policies management for their clients. Auth also issues temporary credentials for the services' clients and validates them for the services
 *
 * OpenAPI spec version: 1.0.2
 * 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 com.akeyless.auth.swagger.model;

import java.util.Objects;
import com.google.gson.TypeAdapter;
import com.google.gson.annotations.JsonAdapter;
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.IOException;

/**
 * PolicyRules
 */
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-11-21T16:11:23.052+02:00")
public class PolicyRules {
  @SerializedName("alg")
  private String alg = null;

  @SerializedName("cidr_whitelist")
  private String cidrWhitelist = null;

  @SerializedName("key")
  private String key = null;

  public PolicyRules alg(String alg) {
    this.alg = alg;
    return this;
  }

   /**
   * Get alg
   * @return alg
  **/
  @ApiModelProperty(value = "")
  public String getAlg() {
    return alg;
  }

  public void setAlg(String alg) {
    this.alg = alg;
  }

  public PolicyRules cidrWhitelist(String cidrWhitelist) {
    this.cidrWhitelist = cidrWhitelist;
    return this;
  }

   /**
   * An CIDR Whitelisting. Only requests from the ip addresses that match the CIDR list will be able to obtain temporary access credentials. The format of the CIDR list is a comma-separated list of valid CIDRs.The list length is limited to 10 CIDRs. In the case of an empty string there will be no restriction of IP addresses.
   * @return cidrWhitelist
  **/
  @ApiModelProperty(value = "An CIDR Whitelisting. Only requests from the ip addresses that match the CIDR list will be able to obtain temporary access credentials. The format of the CIDR list is a comma-separated list of valid CIDRs.The list length is limited to 10 CIDRs. In the case of an empty string there will be no restriction of IP addresses.")
  public String getCidrWhitelist() {
    return cidrWhitelist;
  }

  public void setCidrWhitelist(String cidrWhitelist) {
    this.cidrWhitelist = cidrWhitelist;
  }

  public PolicyRules key(String key) {
    this.key = key;
    return this;
  }

   /**
   * The public key value of the API-key. This is a mandatory parameter for API key policy.
   * @return key
  **/
  @ApiModelProperty(value = "The public key value of the API-key. This is a mandatory parameter for API key policy.")
  public String getKey() {
    return key;
  }

  public void setKey(String key) {
    this.key = key;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    PolicyRules policyRules = (PolicyRules) o;
    return Objects.equals(this.alg, policyRules.alg) &&
        Objects.equals(this.cidrWhitelist, policyRules.cidrWhitelist) &&
        Objects.equals(this.key, policyRules.key);
  }

  @Override
  public int hashCode() {
    return Objects.hash(alg, cidrWhitelist, key);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class PolicyRules {\n");
    
    sb.append("    alg: ").append(toIndentedString(alg)).append("\n");
    sb.append("    cidrWhitelist: ").append(toIndentedString(cidrWhitelist)).append("\n");
    sb.append("    key: ").append(toIndentedString(key)).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(java.lang.Object o) {
    if (o == null) {
      return "null";
    }
    return o.toString().replace("\n", "\n    ");
  }

}





© 2015 - 2024 Weber Informatics LLC | Privacy Policy