package com.airlock.iam.flow.domain.model;

import com.airlock.iam.flow.api.domain.model.flow.FlowId;
import com.airlock.iam.flow.api.domain.model.step.StepAction;
import com.airlock.iam.flow.types.api.domain.model.session.MultiFlowType;
import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;

public final class FlowInformation {
   private final FlowId flowId;
   private final MultiFlowType flowType;
   private final StepAction nextStep;

   @SuppressFBWarnings(justification = "generated code")
   public FlowInformation(FlowId flowId, MultiFlowType flowType, StepAction nextStep) {
      this.flowId = flowId;
      this.flowType = flowType;
      this.nextStep = nextStep;
   }

   @SuppressFBWarnings(justification = "generated code")
   public FlowId getFlowId() {
      return this.flowId;
   }

   @SuppressFBWarnings(justification = "generated code")
   public MultiFlowType getFlowType() {
      return this.flowType;
   }

   @SuppressFBWarnings(justification = "generated code")
   public StepAction getNextStep() {
      return this.nextStep;
   }

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

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

   @SuppressFBWarnings(justification = "generated code")
   @Override
   public String toString() {
      return "FlowInformation(flowId=" + this.getFlowId() + ", flowType=" + this.getFlowType() + ", nextStep=" + this.getNextStep() + ")";
   }
}
