package cn.iocoder.yudao.module.identity.enums;

import cn.iocoder.yudao.framework.common.core.IntArrayValuable;
import lombok.AllArgsConstructor;
import lombok.Getter;

import java.util.Arrays;

@Getter
@AllArgsConstructor
public enum CodeTypeEnums implements IntArrayValuable {
    GENERAL_CODE(0, "普通码"),
    SECRET_CODE(1, "明暗码"),
    ;

    public static final int[] ARRAYS = Arrays.stream(values()).mapToInt(CodeTypeEnums::getCodeType).toArray();

    /**
     * 码类型
     */
    private final Integer codeType;

    /**
     * 类型名
     */
    private final String typeName;

    @Override
    public int[] array() {
        return ARRAYS;
    }

}
