浏览代码

jfinal 3.6

James 7 年之前
父节点
当前提交
a9e9f5a988
共有 1 个文件被更改,包括 9 次插入1 次删除
  1. 9 1
      src/main/java/com/jfinal/kit/Prop.java

+ 9 - 1
src/main/java/com/jfinal/kit/Prop.java

@@ -29,7 +29,7 @@ import com.jfinal.core.Const;
  */
 public class Prop {
 	
-	protected Properties properties = null;
+	protected Properties properties;
 	
 	/**
 	 * 支持 new Prop().appendIfExists(...)
@@ -221,6 +221,14 @@ public class Prop {
 		return properties.containsKey(key);
 	}
 	
+	public boolean isEmpty() {
+		return properties.isEmpty();
+	}
+	
+	public boolean notEmpty() {
+		return ! properties.isEmpty();
+	}
+	
 	public Properties getProperties() {
 		return properties;
 	}