io.github.xtazxz.base.common.ec.define.ErrorCodeSecurity Maven / Gradle / Ivy
The newest version!
package io.github.xtazxz.base.common.ec.define;
import io.github.xtazxz.base.common.ec.ErrorCodeBase;
import io.github.xtazxz.base.entity.ErrorCode;
public class ErrorCodeSecurity {
public static ErrorCode unauthorized() {
return ErrorCode.business(ErrorCodeBase.EC_BASE_SECURITY + 1, "没有认证");
}
public static ErrorCode forbidden() {
return ErrorCode.business(ErrorCodeBase.EC_BASE_SECURITY + 2, "没有权限");
}
public static ErrorCode userNotExist() {
return ErrorCode.business(ErrorCodeBase.EC_BASE_SECURITY + 3, "用户不存在");
}
public static ErrorCode usernameOrPasswordError() {
return ErrorCode.business(ErrorCodeBase.EC_BASE_SECURITY + 4, "用户名或者密码错误");
}
}