package com.airlock.iam.oauth2.infrastructure.transfer.request;

import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Size;

public class OpenIdConnectCheckOriginRequest {
   @NotNull
   @Schema(description = "Origin to check.", minLength = 1, maxLength = 100000)
   @Size(min = 1, max = 100000)
   private String origin;
   @NotNull
   @Schema(description = "The ID of the registered client on this authorization server.", minLength = 1, maxLength = 10000)
   @Size(min = 1, max = 10000)
   private String clientId;

   @SuppressFBWarnings(justification = "generated code")
   public String getOrigin() {
      return this.origin;
   }

   @SuppressFBWarnings(justification = "generated code")
   public String getClientId() {
      return this.clientId;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setOrigin(String origin) {
      this.origin = origin;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setClientId(String clientId) {
      this.clientId = clientId;
   }

   @SuppressFBWarnings(justification = "generated code")
   @Override
   public boolean equals(Object o) {
      if (o == this) {
         return true;
      } else if (!(o instanceof OpenIdConnectCheckOriginRequest other)) {
         return false;
      } else if (!other.canEqual(this)) {
         return false;
      } else {
         Object this$origin = this.origin;
         Object other$origin = other.origin;
         if (this$origin == null ? other$origin == null : this$origin.equals(other$origin)) {
            Object this$clientId = this.clientId;
            Object other$clientId = other.clientId;
            return this$clientId == null ? other$clientId == null : this$clientId.equals(other$clientId);
         } else {
            return false;
         }
      }
   }

   @SuppressFBWarnings(justification = "generated code")
   protected boolean canEqual(Object other) {
      return other instanceof OpenIdConnectCheckOriginRequest;
   }

   @SuppressFBWarnings(justification = "generated code")
   @Override
   public int hashCode() {
      int PRIME = 59;
      int result = 1;
      Object $origin = this.origin;
      result = result * 59 + ($origin == null ? 43 : $origin.hashCode());
      Object $clientId = this.clientId;
      return result * 59 + ($clientId == null ? 43 : $clientId.hashCode());
   }

   @SuppressFBWarnings(justification = "generated code")
   @Override
   public String toString() {
      return "OpenIdConnectCheckOriginRequest(origin=" + this.getOrigin() + ", clientId=" + this.getClientId() + ")";
   }
}
