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

de.adorsys.multibanking.banking_gateway_b2c.model.UpdateAuthResponseTO Maven / Gradle / Ivy

/*
 * Bankinggateway B2C Rest API
 * No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
 *
 * OpenAPI spec version: 0.2-SNAPSHOT
 * 
 *
 * 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 de.adorsys.multibanking.banking_gateway_b2c.model;

import java.util.Objects;
import java.util.Arrays;
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 de.adorsys.multibanking.banking_gateway_b2c.model.ChallengeDataTO;
import de.adorsys.multibanking.banking_gateway_b2c.model.ScaMethodTO;
import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
/**
 * UpdateAuthResponseTO
 */

@javax.annotation.Generated(value = "io.swagger.codegen.v3.generators.java.JavaClientCodegen", date = "2020-03-31T11:42:30.614Z[UTC]")
public class UpdateAuthResponseTO {
  /**
   * Gets or Sets scaStatus
   */
  @JsonAdapter(ScaStatusEnum.Adapter.class)
  public enum ScaStatusEnum {
    RECEIVED("RECEIVED"),
    STARTED("STARTED"),
    PSUIDENTIFIED("PSUIDENTIFIED"),
    PSUAUTHENTICATED("PSUAUTHENTICATED"),
    SCAMETHODSELECTED("SCAMETHODSELECTED"),
    FINALISED("FINALISED"),
    FAILED("FAILED"),
    EXEMPTED("EXEMPTED");

    private String value;

    ScaStatusEnum(String value) {
      this.value = value;
    }
    public String getValue() {
      return value;
    }

    @Override
    public String toString() {
      return String.valueOf(value);
    }
    public static ScaStatusEnum fromValue(String text) {
      for (ScaStatusEnum b : ScaStatusEnum.values()) {
        if (String.valueOf(b.value).equals(text)) {
          return b;
        }
      }
      return null;
    }
    public static class Adapter extends TypeAdapter {
      @Override
      public void write(final JsonWriter jsonWriter, final ScaStatusEnum enumeration) throws IOException {
        jsonWriter.value(enumeration.getValue());
      }

      @Override
      public ScaStatusEnum read(final JsonReader jsonReader) throws IOException {
        String value = jsonReader.nextString();
        return ScaStatusEnum.fromValue(String.valueOf(value));
      }
    }
  }  @SerializedName("scaStatus")
  private ScaStatusEnum scaStatus = null;

  /**
   * Gets or Sets scaApproach
   */
  @JsonAdapter(ScaApproachEnum.Adapter.class)
  public enum ScaApproachEnum {
    EMBEDDED("EMBEDDED"),
    REDIRECT("REDIRECT"),
    DECOUPLED("DECOUPLED"),
    OAUTH("OAUTH"),
    OAUTH_PRESTEP("OAUTH_PRESTEP");

    private String value;

    ScaApproachEnum(String value) {
      this.value = value;
    }
    public String getValue() {
      return value;
    }

    @Override
    public String toString() {
      return String.valueOf(value);
    }
    public static ScaApproachEnum fromValue(String text) {
      for (ScaApproachEnum b : ScaApproachEnum.values()) {
        if (String.valueOf(b.value).equals(text)) {
          return b;
        }
      }
      return null;
    }
    public static class Adapter extends TypeAdapter {
      @Override
      public void write(final JsonWriter jsonWriter, final ScaApproachEnum enumeration) throws IOException {
        jsonWriter.value(enumeration.getValue());
      }

      @Override
      public ScaApproachEnum read(final JsonReader jsonReader) throws IOException {
        String value = jsonReader.nextString();
        return ScaApproachEnum.fromValue(String.valueOf(value));
      }
    }
  }  @SerializedName("scaApproach")
  private ScaApproachEnum scaApproach = null;

  @SerializedName("scaMethods")
  private List scaMethods = null;

  @SerializedName("challenge")
  private ChallengeDataTO challenge = null;

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

  public UpdateAuthResponseTO scaStatus(ScaStatusEnum scaStatus) {
    this.scaStatus = scaStatus;
    return this;
  }

   /**
   * Get scaStatus
   * @return scaStatus
  **/
  @Schema(description = "")
  public ScaStatusEnum getScaStatus() {
    return scaStatus;
  }

  public void setScaStatus(ScaStatusEnum scaStatus) {
    this.scaStatus = scaStatus;
  }

  public UpdateAuthResponseTO scaApproach(ScaApproachEnum scaApproach) {
    this.scaApproach = scaApproach;
    return this;
  }

   /**
   * Get scaApproach
   * @return scaApproach
  **/
  @Schema(description = "")
  public ScaApproachEnum getScaApproach() {
    return scaApproach;
  }

  public void setScaApproach(ScaApproachEnum scaApproach) {
    this.scaApproach = scaApproach;
  }

  public UpdateAuthResponseTO scaMethods(List scaMethods) {
    this.scaMethods = scaMethods;
    return this;
  }

  public UpdateAuthResponseTO addScaMethodsItem(ScaMethodTO scaMethodsItem) {
    if (this.scaMethods == null) {
      this.scaMethods = new ArrayList<>();
    }
    this.scaMethods.add(scaMethodsItem);
    return this;
  }

   /**
   * This data element might be contained, if SCA is required and if the PSU has a choice between different authentication methods. These methods shall be presented towards the PSU for selection by the TPP.
   * @return scaMethods
  **/
  @Schema(description = "This data element might be contained, if SCA is required and if the PSU has a choice between different authentication methods. These methods shall be presented towards the PSU for selection by the TPP.")
  public List getScaMethods() {
    return scaMethods;
  }

  public void setScaMethods(List scaMethods) {
    this.scaMethods = scaMethods;
  }

  public UpdateAuthResponseTO challenge(ChallengeDataTO challenge) {
    this.challenge = challenge;
    return this;
  }

   /**
   * Get challenge
   * @return challenge
  **/
  @Schema(description = "")
  public ChallengeDataTO getChallenge() {
    return challenge;
  }

  public void setChallenge(ChallengeDataTO challenge) {
    this.challenge = challenge;
  }

  public UpdateAuthResponseTO psuMessage(String psuMessage) {
    this.psuMessage = psuMessage;
    return this;
  }

   /**
   * Text to be displayed to the PSU
   * @return psuMessage
  **/
  @Schema(description = "Text to be displayed to the PSU")
  public String getPsuMessage() {
    return psuMessage;
  }

  public void setPsuMessage(String psuMessage) {
    this.psuMessage = psuMessage;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    UpdateAuthResponseTO updateAuthResponseTO = (UpdateAuthResponseTO) o;
    return Objects.equals(this.scaStatus, updateAuthResponseTO.scaStatus) &&
        Objects.equals(this.scaApproach, updateAuthResponseTO.scaApproach) &&
        Objects.equals(this.scaMethods, updateAuthResponseTO.scaMethods) &&
        Objects.equals(this.challenge, updateAuthResponseTO.challenge) &&
        Objects.equals(this.psuMessage, updateAuthResponseTO.psuMessage);
  }

  @Override
  public int hashCode() {
    return Objects.hash(scaStatus, scaApproach, scaMethods, challenge, psuMessage);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class UpdateAuthResponseTO {\n");
    
    sb.append("    scaStatus: ").append(toIndentedString(scaStatus)).append("\n");
    sb.append("    scaApproach: ").append(toIndentedString(scaApproach)).append("\n");
    sb.append("    scaMethods: ").append(toIndentedString(scaMethods)).append("\n");
    sb.append("    challenge: ").append(toIndentedString(challenge)).append("\n");
    sb.append("    psuMessage: ").append(toIndentedString(psuMessage)).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