package io.castle.client.model;

import com.google.gson.JsonElement;

/**
 * Model of the outcome of an authenticate call to the Castle API.
 */
public class Verdict {

    /**
     * AuthenticateAction returned by a call to the CastleAPI, or configured by a failover strategy.
     */
    private AuthenticateAction action;

    /**
     * String representing a user ID associated with an authenticate call.
     */
    private String userId;

    /**
     * True if the SDK resorted the {@code AuthenticateFailoverStrategy} configured.
     */
    private boolean failover;

    /**
     * Explains the reason why the {@code AuthenticateFailoverStrategy} was used.
     */
    private String failoverReason;

    /**
     * String representing a device ID associated with an authenticate call.
     */
    private String deviceToken;

    /**
     * Integer representing risk value associated with an authenticate call.
     */
    private int risk;

    /**
     * RiskPolicyResult representing risk policy used for generating this verdict.
     */
    private RiskPolicyResult riskPolicy;

    /**
     * JsonElement representing the full response of the server request
     */
    private JsonElement internal;

    public AuthenticateAction getAction() {
        return action;
    }

    public void setAction(AuthenticateAction action) {
        this.action = action;
    }

    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    public boolean isFailover() {
        return failover;
    }

    public void setFailover(boolean failover) {
        this.failover = failover;
    }

    public String getFailoverReason() {
        return failoverReason;
    }

    public void setFailoverReason(String failoverReason) {
        this.failoverReason = failoverReason;
    }

    public String getDeviceToken() {
        return deviceToken;
    }

    public void setRisk(int risk) {
        this.risk = risk;
    }

    public int getRisk() {
        return risk;
    }

    public void setDeviceToken(String deviceToken) {
        this.deviceToken = deviceToken;
    }

    public void setInternal(JsonElement internal) {
        this.internal = internal;
    }

    public RiskPolicyResult getRiskPolicy() {
        return riskPolicy;
    }

    public void setRiskPolicy(RiskPolicyResult riskPolicy) {
        this.riskPolicy = riskPolicy;
    }
}

package io.castle.client.model;

import com.google.gson.JsonElement;

/**
 * Model of the outcome of an authenticate call to the Castle API.
 */
public class Verdict {

    /**
     * AuthenticateAction returned by a call to the CastleAPI, or configured by a failover strategy.
     */
    private AuthenticateAction action;

    /**
     * String representing a user ID associated with an authenticate call.
     */
    private String userId;

    /**
     * True if the SDK resorted the {@code AuthenticateFailoverStrategy} configured.
     */
    private boolean failover;

    /**
     * Explains the reason why the {@code AuthenticateFailoverStrategy} was used.
     */
    private String failoverReason;

    /**
     * String representing a device ID associated with an authenticate call.
     */
    private String deviceToken;

    /**
     * Flott representing risk value associated with an authenticate call.
     */
    private float risk;

    /**
     * RiskPolicyResult representing risk policy used for generating this verdict.
     */
    private RiskPolicyResult riskPolicy;

    /**
     * JsonElement representing the full response of the server request
     */
    private JsonElement internal;

    public AuthenticateAction getAction() {
        return action;
    }

    public void setAction(AuthenticateAction action) {
        this.action = action;
    }

    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    public boolean isFailover() {
        return failover;
    }

    public void setFailover(boolean failover) {
        this.failover = failover;
    }

    public String getFailoverReason() {
        return failoverReason;
    }

    public void setFailoverReason(String failoverReason) {
        this.failoverReason = failoverReason;
    }

    public String getDeviceToken() {
        return deviceToken;
    }

    public void setRisk(float risk) {
        this.risk = risk;
    }

    public float getRisk() {
        return risk;
    }

    public void setDeviceToken(String deviceToken) {
        this.deviceToken = deviceToken;
    }

    public void setInternal(JsonElement internal) {
        this.internal = internal;
    }

    public RiskPolicyResult getRiskPolicy() {
        return riskPolicy;
    }

    public void setRiskPolicy(RiskPolicyResult riskPolicy) {
        this.riskPolicy = riskPolicy;
    }
}

Use float for risk field in Verdict (#91)