package com.sckw.core.common.enums.enums;

/**
 * @author lfdc
 * @description 文件格式布局枚举
 * @date 2023-10-07 09:10:42
 */
public enum FileDisposeLayoutEnum {

    /**
     * ?x-oss-process=image/resize,m_lfit,h_200,w_200
     *
     * 图片格式只能是：JPG、PNG、BMP、GIF、WebP、TIFF。
     */

    /**
     * oss裁剪比例大小-左
     */
    OSS_ABBREVIATE_LEFT(FileEnum.FILE_STORE_TYPE_OSS.getFileType(), "?x-oss-process=image/resize,m_lfit,h_", "OSS设置文件大小"),

    /**
     * oss裁剪比例大小-右
     */
    OSS_ABBREVIATE_RIGHT(FileEnum.FILE_STORE_TYPE_OSS.getFileType(), ",w_", "OSS设置文件大小"),
    /**
     * oss按照比例缩放
     */
    OSS_LESSEN(FileEnum.FILE_STORE_TYPE_OSS.getFileType(), "?x-oss-process=image/resize,p_", "按百分比缩放"),
    /**
     * 七牛云缩略图
     */
    KODO_ABBREVIATE(FileEnum.FILE_STORE_TYPE_ALIYUN.getFileType(), "-indexthumb", "缩略图"),
    ;

    private final String type;
    private final String parameter;
    private final String description;

    public String getType() {
        return type;
    }

    public String getParameter() {
        return parameter;
    }

    public String getDescription() {
        return description;
    }

    FileDisposeLayoutEnum(String type, String parameter, String description) {
        this.type = type;
        this.parameter = parameter;
        this.description = description;
    }
}
