package com.backendsys.modules.upload.entity;

import jakarta.validation.constraints.NotEmpty;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Size;
import lombok.Data;

@Data
public class MultipartUploadParams {

    public static interface Init{}

    @NotEmpty(message = "文件名称不能为空", groups = { Init.class })
    @Size(max = 50, message = "文件名称长度不超过 {max} 字符", groups = { Init.class })
    private String filename;
    private Long category_id;
    @NotNull(message = "分块数量不能为空", groups = { Init.class })
    private Integer upload_chunk_count;
    @NotEmpty(message = "md5 不能为空", groups = { Init.class })
    private String md5;
    @NotEmpty(message = "content_type 不能为空", groups = {})
    private String content_type;
    @NotNull(message = "size 不能为空", groups = { Init.class })
    private Long size;

}
