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

net.leanix.mtm.api.models.PersonalAccessToken Maven / Gradle / Ivy

There is a newer version: 1.7.25
Show newest version
package net.leanix.mtm.api.models;

import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModelProperty;

import java.util.ArrayList;
import java.util.List;
import java.util.Objects;






public class PersonalAccessToken   {
  
  private String token = null;
  private String userId = null;
  private String workspaceId = null;
  private String expiry = null;
  private List scopes = new ArrayList();
  private String description = null;
  private String creatorId = null;
  private String id = null;

  
  /**
   **/
  public PersonalAccessToken token(String token) {
    this.token = token;
    return this;
  }
  
  @ApiModelProperty(example = "null", value = "")
  @JsonProperty("token")
  public String getToken() {
    return token;
  }
  public void setToken(String token) {
    this.token = token;
  }

  
  /**
   **/
  public PersonalAccessToken userId(String userId) {
    this.userId = userId;
    return this;
  }
  
  @ApiModelProperty(example = "null", value = "")
  @JsonProperty("userId")
  public String getUserId() {
    return userId;
  }
  public void setUserId(String userId) {
    this.userId = userId;
  }

  
  /**
   **/
  public PersonalAccessToken workspaceId(String workspaceId) {
    this.workspaceId = workspaceId;
    return this;
  }
  
  @ApiModelProperty(example = "null", value = "")
  @JsonProperty("workspaceId")
  public String getWorkspaceId() {
    return workspaceId;
  }
  public void setWorkspaceId(String workspaceId) {
    this.workspaceId = workspaceId;
  }

  
  /**
   **/
  public PersonalAccessToken expiry(String expiry) {
    this.expiry = expiry;
    return this;
  }
  
  @ApiModelProperty(example = "null", value = "")
  @JsonProperty("expiry")
  public String getExpiry() {
    return expiry;
  }
  public void setExpiry(String expiry) {
    this.expiry = expiry;
  }

  
  /**
   **/
  public PersonalAccessToken scopes(List scopes) {
    this.scopes = scopes;
    return this;
  }
  
  @ApiModelProperty(example = "null", value = "")
  @JsonProperty("scopes")
  public List getScopes() {
    return scopes;
  }
  public void setScopes(List scopes) {
    this.scopes = scopes;
  }

  
  /**
   **/
  public PersonalAccessToken description(String description) {
    this.description = description;
    return this;
  }
  
  @ApiModelProperty(example = "null", value = "")
  @JsonProperty("description")
  public String getDescription() {
    return description;
  }
  public void setDescription(String description) {
    this.description = description;
  }

  
  /**
   **/
  public PersonalAccessToken creatorId(String creatorId) {
    this.creatorId = creatorId;
    return this;
  }
  
  @ApiModelProperty(example = "null", value = "")
  @JsonProperty("creatorId")
  public String getCreatorId() {
    return creatorId;
  }
  public void setCreatorId(String creatorId) {
    this.creatorId = creatorId;
  }

  
  /**
   **/
  public PersonalAccessToken id(String id) {
    this.id = id;
    return this;
  }
  
  @ApiModelProperty(example = "null", value = "")
  @JsonProperty("id")
  public String getId() {
    return id;
  }
  public void setId(String id) {
    this.id = id;
  }

  

  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    PersonalAccessToken personalAccessToken = (PersonalAccessToken) o;
    return Objects.equals(this.token, personalAccessToken.token) &&
        Objects.equals(this.userId, personalAccessToken.userId) &&
        Objects.equals(this.workspaceId, personalAccessToken.workspaceId) &&
        Objects.equals(this.expiry, personalAccessToken.expiry) &&
        Objects.equals(this.scopes, personalAccessToken.scopes) &&
        Objects.equals(this.description, personalAccessToken.description) &&
        Objects.equals(this.creatorId, personalAccessToken.creatorId) &&
        Objects.equals(this.id, personalAccessToken.id);
  }

  @Override
  public int hashCode() {
    return Objects.hash(token, userId, workspaceId, expiry, scopes, description, creatorId, id);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class PersonalAccessToken {\n");
    
    sb.append("    token: ").append(toIndentedString(token)).append("\n");
    sb.append("    userId: ").append(toIndentedString(userId)).append("\n");
    sb.append("    workspaceId: ").append(toIndentedString(workspaceId)).append("\n");
    sb.append("    expiry: ").append(toIndentedString(expiry)).append("\n");
    sb.append("    scopes: ").append(toIndentedString(scopes)).append("\n");
    sb.append("    description: ").append(toIndentedString(description)).append("\n");
    sb.append("    creatorId: ").append(toIndentedString(creatorId)).append("\n");
    sb.append("    id: ").append(toIndentedString(id)).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 - 2025 Weber Informatics LLC | Privacy Policy