package com.hmit.kernes.validator;
import org.apache.commons.lang.StringUtils;
import com.hmit.kernes.utils.RRException;
/**
* 数据校验
* @author kernespring
* @email kernespring@gmail.com
* @date 2017-03-23 15:50
*/
public abstract class Assert {
public static void isBlank(String str, String message) {
if (StringUtils.isBlank(str)) {
throw new RRException(message);
}
}
public static void isNull(Object object, String message) {
if (object == null) {
throw new RRException(message);
}
}
}
-
Zhou Yang authored42192484