com.checkmarx.sdk.dto.cx.CxAuthResponse Maven / Gradle / Ivy
package com.checkmarx.sdk.dto.cx;
import com.fasterxml.jackson.annotation.JsonProperty;
public class CxAuthResponse {
@JsonProperty("AccessToken")
private String accessToken;
@JsonProperty("IdToken")
private String idToken;
@JsonProperty("ExpiresIn")
private Long expiresIn;
@JsonProperty("TokenType")
private String tokenType;
@java.beans.ConstructorProperties({"accessToken", "idToken", "expiresIn", "tokenType"})
public CxAuthResponse(String accessToken, String idToken, Long expiresIn, String tokenType) {
this.accessToken = accessToken;
this.idToken = idToken;
this.expiresIn = expiresIn;
this.tokenType = tokenType;
}
public static CxAuthResponseBuilder builder() {
return new CxAuthResponseBuilder();
}
public String toString() {
return "CxAuthResponse(accessToken=" + this.getAccessToken() + ", expiresIn=" + this.getExpiresIn() + ", tokenType=" + this.getTokenType() + ")";
}
public String getAccessToken() {
return this.accessToken;
}
public String getIdToken() {
return this.idToken;
}
public Long getExpiresIn() {
return this.expiresIn;
}
public String getTokenType() {
return this.tokenType;
}
public static class CxAuthResponseBuilder {
private String accessToken;
private String idToken;
private Long expiresIn;
private String tokenType;
CxAuthResponseBuilder() {
}
public CxAuthResponse.CxAuthResponseBuilder accessToken(String accessToken) {
this.accessToken = accessToken;
return this;
}
public CxAuthResponse.CxAuthResponseBuilder expiresIn(Long expiresIn) {
this.expiresIn = expiresIn;
return this;
}
public CxAuthResponse.CxAuthResponseBuilder tokenType(String tokenType) {
this.tokenType = tokenType;
return this;
}
public CxAuthResponse build() {
return new CxAuthResponse(accessToken, idToken, expiresIn, tokenType);
}
public String toString() {
return "CxAuthResponse.CxAuthResponseBuilder(accessToken=" + this.accessToken + ", expiresIn=" + this.expiresIn + ", tokenType=" + this.tokenType + ")";
}
}
}