public class PropertiesReader extends Object
| Constructor and Description |
|---|
PropertiesReader() |
| Modifier and Type | Method and Description |
|---|---|
static ArrayList<String> |
getAllFiles(File curDir)
gets all files in a directory to get all files: File curDir = new File(".");
getAllFiles(curDir);
|
static String |
getLocalResourcePath() |
static String |
getLocalRootPath() |
static List<Properties> |
getPropertiesByFileType(String path,
String fileType)
gets all properties file by file type in a directory
|
static String |
getStringProperty(String key,
Properties Property)
gets the value of the properties file based on key value, And sets default
value if value is missing
|
static boolean |
isUsingCloud() |
static List<Properties> |
Property(String path) |
public static List<Properties> Property(String path) throws Exception
path - path to properties fileException - exception from getting properties filepublic static List<Properties> getPropertiesByFileType(String path, String fileType) throws Exception
path: - directory pathfileType: - eg. ".conf"Exception - exception from getting properties filepublic static String getLocalRootPath()
public static String getLocalResourcePath()
public static boolean isUsingCloud()
public static String getStringProperty(String key, Properties Property)
key - key in properties fileProperty - target properties from property fileCopyright © 2019. All rights reserved.