All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.github.linmoure.constants.Constants Maven / Gradle / Ivy

There is a newer version: 1.1.1
Show newest version
package io.github.linmoure.constants;

import io.github.linmoure.utils.SnowFlake;
import org.apache.commons.lang3.math.NumberUtils;

import java.util.UUID;

/**
 * @author 李衡林
 */
public class Constants extends NumberUtils {

    public static final String STRING_0 = "0";

    public static final String STRING_1 = "1";

    public static final String STRING_2 = "2";

    public static final String STRING_3 = "3";

    public static final String STRING_4 = "4";

    public static final String STRING_5 = "5";

    public static final String STRING_6 = "6";

    public static final String STRING_7 = "7";

    public static final String STRING_8 = "8";

    public static final String STRING_9 = "9";

    public static final Integer INTEGER_0 = 0;

    public static final Integer INTEGER_1 = 1;

    public static final Integer INTEGER_2 = 2;

    public static final Integer INTEGER_3 = 3;

    public static final Integer INTEGER_4 = 4;

    public static final Integer INTEGER_5 = 5;

    public static final Integer INTEGER_6 = 6;

    public static final Integer INTEGER_7 = 7;

    public static final Integer INTEGER_8 = 8;

    public static final Integer INTEGER_9 = 9;

    public static final int INT_0 = 0;

    public static final int INT_1 = 1;

    public static final int INT_2 = 2;

    public static final int INT_3 = 3;

    public static final int INT_4 = 4;

    public static final int INT_5 = 5;

    public static final int INT_6 = 6;

    public static final int INT_7 = 7;

    public static final int INT_8 = 8;

    public static final int INT_9 = 9;

    public static final Long LONG_0 = 0L;

    public static final Long LONG_1 = 1L;

    public static final Long LONG_2 = 2L;

    public static final Long LONG_3 = 3L;

    public static final Long LONG_4 = 4L;

    public static final Long LONG_5 = 5L;

    public static final Long LONG_6 = 6L;

    public static final Long LONG_7 = 7L;

    public static final Long LONG_8 = 8L;

    public static final Long LONG_9 = 9L;

    public static final String STRING_TRUE = "true";

    public static final String STRING_FALSE = "false";

    public static final Boolean BOOLEAN_TRUE = Boolean.TRUE;

    public static final Boolean BOOLEAN_FALSE = Boolean.FALSE;

    public static final boolean TRUE = Boolean.TRUE.booleanValue();

    public static final boolean FALSE = Boolean.FALSE.booleanValue();

    public static final String SPRING_PROFILE_ACTIVE_DEV = "dev";

    public static final String SPRING_PROFILE_ACTIVE_LOCAL = "local";

    public static boolean CHECK_IP;

    public static final String REGION = "内网IP|内网IP";

    public static final String DB_TYPE = "mongo";

    public static long nextId() {
        return SnowFlake.getInstance().nextId();
    }

    public static String uuid() {
        return UUID.randomUUID().toString().replace("-", "");
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy