package ru.soune.nocopy.dto.statistic;

import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
public class IncomeStatisticResponse {

    @JsonProperty("total_income")
    private Long totalIncome;

    @JsonProperty("total_available")
    private Long totalAvailable;

    @JsonProperty("total_hold")
    private Long totalHold;

    @JsonProperty("income_per_user")
    private Percentiles incomePerUser;

    @Data
    @AllArgsConstructor
    @NoArgsConstructor
    public static class Percentiles {
        @JsonProperty("p5")
        private Long p5;

        @JsonProperty("p50")
        private Long p50;

        @JsonProperty("p95")
        private Long p95;
    }
}
