package com.airlock.iam.authentication.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 final class Airlock2FAOfflineQrCodeCheckRequest {
   @NotNull
   @Schema(description = "The Offline QR Code OTP to be checked.", maxLength = 40)
   @Size(max = 40)
   private String otp;

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

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

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

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

   @SuppressFBWarnings(justification = "generated code")
   @Override
   public String toString() {
      return "Airlock2FAOfflineQrCodeCheckRequest(otp=" + this.getOtp() + ")";
   }

   @SuppressFBWarnings(justification = "generated code")
   public Airlock2FAOfflineQrCodeCheckRequest() {
   }

   @SuppressFBWarnings(justification = "generated code")
   public Airlock2FAOfflineQrCodeCheckRequest(String otp) {
      this.otp = otp;
   }
}
