public class ProjectProperties extends Object
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_NAME
The default property file
|
static String |
SYSTEM_PROPERTY
System property
|
Constructor and Description |
---|
ProjectProperties(Class clazz)
Loads the properties from the resources.
|
ProjectProperties(File file)
Loads the properties
|
ProjectProperties(InputStream is)
Loads the properties
|
ProjectProperties(Reader reader)
Loads the properties
|
ProjectProperties(String file)
Loads the properties
|
Modifier and Type | Method and Description |
---|---|
String |
get(String key)
Gets a property
|
double |
getDouble(String key)
Gets a int property
|
int |
getInt(String key)
Gets a int property
|
boolean |
has(String key)
Checks if the a property is defined
|
boolean |
is(String key)
Gets a boolean property
|
void |
set(String key,
String value)
Sets a property
|
public static final String DEFAULT_NAME
public static final String SYSTEM_PROPERTY
public ProjectProperties(String file)
file
- the property filepublic ProjectProperties(Class clazz)
clazz
- the current classpublic ProjectProperties(File file)
file
- the property filepublic ProjectProperties(InputStream is)
is
- the property filepublic ProjectProperties(Reader reader)
reader
- the property filepublic int getInt(String key)
key
- the property key.public double getDouble(String key)
key
- the property key.public boolean is(String key)
key
- the property key.public boolean has(String key)
key
- the property to checkCopyright © 2013. All rights reserved.