public class PropertiesUtil extends Object
| 构造器和说明 |
|---|
PropertiesUtil() |
| 限定符和类型 | 方法和说明 |
|---|---|
static String |
GetAllProperties(String filePath)
读取Properties的全部信息
|
static String |
GetValueByKey(String filePath,
String key)
根据Key读取Value
|
static String |
key(String key)
从系统属性文件中获取相应的值
|
static void |
WriteProperties(String filePath,
String pKey,
String pValue)
写入Properties信息
|
public static String GetValueByKey(String filePath, String key)
filePath - 属性文件key - 需要读取的属性public static String GetAllProperties(String filePath) throws IOException
filePath - 读取的属性文件IOExceptionpublic static void WriteProperties(String filePath, String pKey, String pValue) throws IOException
filePath - 写入的属性文件pKey - 属性名称pValue - 属性值IOExceptionCopyright © 2016. All rights reserved.