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

com.klarna.rest.api.hosted_payment_page.model.HPPSessionCreationResponseV1 Maven / Gradle / Ivy

The newest version!
/*
 * HPP
 * Hosted Payment Page
 *
 * OpenAPI spec version: 1.0
 * 
 *
 * 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.klarna.rest.api.hosted_payment_page.model;

import java.util.Objects;
import java.util.Arrays;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

/**
 * HPPSessionCreationResponseV1
 */
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2020-01-20T10:31:07.217Z")
public class HPPSessionCreationResponseV1 {
  @JsonProperty("distribution_url")
  private String distributionUrl = null;

  @JsonProperty("qr_code_url")
  private String qrCodeUrl = null;

  @JsonProperty("redirect_url")
  private String redirectUrl = null;

  @JsonProperty("session_id")
  private String sessionId = null;

  @JsonProperty("session_url")
  private String sessionUrl = null;

  public HPPSessionCreationResponseV1 distributionUrl(String distributionUrl) {
    this.distributionUrl = distributionUrl;
    return this;
  }

   /**
   * Endpoint for link distribution
   * @return distributionUrl
  **/
  @ApiModelProperty(example = "https://api.klarna.com/hpp/v1/sessions/9cbc9884-1fdb-45a8-9694-9340340d0436/distribution", value = "Endpoint for link distribution")
  public String getDistributionUrl() {
    return distributionUrl;
  }

  public void setDistributionUrl(String distributionUrl) {
    this.distributionUrl = distributionUrl;
  }

  public HPPSessionCreationResponseV1 qrCodeUrl(String qrCodeUrl) {
    this.qrCodeUrl = qrCodeUrl;
    return this;
  }

   /**
   * HPP url to download qr code image
   * @return qrCodeUrl
  **/
  @ApiModelProperty(example = "https://payment-eu.klarna.com/hpp/9cbc9884-1fdb-45a8-9694-9340340d0436/qr", value = "HPP url to download qr code image")
  public String getQrCodeUrl() {
    return qrCodeUrl;
  }

  public void setQrCodeUrl(String qrCodeUrl) {
    this.qrCodeUrl = qrCodeUrl;
  }

  public HPPSessionCreationResponseV1 redirectUrl(String redirectUrl) {
    this.redirectUrl = redirectUrl;
    return this;
  }

   /**
   * HPP url to redirect the consumer to
   * @return redirectUrl
  **/
  @ApiModelProperty(example = "https://buy.klarna.com/hpp/9cbc9884-1fdb-45a8-9694-9340340d0436", value = "HPP url to redirect the consumer to")
  public String getRedirectUrl() {
    return redirectUrl;
  }

  public void setRedirectUrl(String redirectUrl) {
    this.redirectUrl = redirectUrl;
  }

  public HPPSessionCreationResponseV1 sessionId(String sessionId) {
    this.sessionId = sessionId;
    return this;
  }

   /**
   * HPP session id
   * @return sessionId
  **/
  @ApiModelProperty(example = "9cbc9884-1fdb-45a8-9694-9340340d0436", value = "HPP session id")
  public String getSessionId() {
    return sessionId;
  }

  public void setSessionId(String sessionId) {
    this.sessionId = sessionId;
  }

  public HPPSessionCreationResponseV1 sessionUrl(String sessionUrl) {
    this.sessionUrl = sessionUrl;
    return this;
  }

   /**
   * Endpoint to read the session
   * @return sessionUrl
  **/
  @ApiModelProperty(example = "https://api.klarna.com/hpp/v1/sessions/9cbc9884-1fdb-45a8-9694-9340340d0436", value = "Endpoint to read the session")
  public String getSessionUrl() {
    return sessionUrl;
  }

  public void setSessionUrl(String sessionUrl) {
    this.sessionUrl = sessionUrl;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    HPPSessionCreationResponseV1 sessionCreationResponseV1 = (HPPSessionCreationResponseV1) o;
    return Objects.equals(this.distributionUrl, sessionCreationResponseV1.distributionUrl) &&
        Objects.equals(this.qrCodeUrl, sessionCreationResponseV1.qrCodeUrl) &&
        Objects.equals(this.redirectUrl, sessionCreationResponseV1.redirectUrl) &&
        Objects.equals(this.sessionId, sessionCreationResponseV1.sessionId) &&
        Objects.equals(this.sessionUrl, sessionCreationResponseV1.sessionUrl);
  }

  @Override
  public int hashCode() {
    return Objects.hash(distributionUrl, qrCodeUrl, redirectUrl, sessionId, sessionUrl);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class HPPSessionCreationResponseV1 {\n");
    
    sb.append("    distributionUrl: ").append(toIndentedString(distributionUrl)).append("\n");
    sb.append("    qrCodeUrl: ").append(toIndentedString(qrCodeUrl)).append("\n");
    sb.append("    redirectUrl: ").append(toIndentedString(redirectUrl)).append("\n");
    sb.append("    sessionId: ").append(toIndentedString(sessionId)).append("\n");
    sb.append("    sessionUrl: ").append(toIndentedString(sessionUrl)).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