package fr.titionfire.ffsaf.utils;

import io.quarkus.runtime.annotations.RegisterForReflection;
import lombok.Data;
import org.eclipse.microprofile.openapi.annotations.media.Schema;

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

@Data
@RegisterForReflection
public class PageResult<T> {
    @Schema(description = "Le numéro de la page courante.", example = "1")
    private int page;
    @Schema(description = "Le nombre d'éléments par page.", example = "10")
    private int page_size;
    @Schema(description = "Le nombre total de pages.", example = "5")
    private int page_count;
    @Schema(description = "Le nombre total d'éléments.", example = "47")
    private long result_count;
    private List<T> result = new ArrayList<>();
}
