public final class PropertyUtils extends Object
| Modifier and Type | Method and Description |
|---|---|
static String |
commonSubstitutions(String input)
Replaces percent-bounded expressions such as "%servletContext%."
|
static String |
getProperty(Properties properties,
org.apache.commons.lang3.tuple.Pair<String,String> propertyWithDefaultValue) |
static boolean |
getProperty(Properties properties,
SimpleBooleanConfigParameter configParameter) |
static <T> T |
getProperty(Properties properties,
SimpleConfigParameter<T> configParameter,
Function<String,T> function) |
static Duration |
getProperty(Properties properties,
SimpleDurationParameter configParameter) |
static int |
getProperty(Properties properties,
SimpleIntConfigParameter configParameter) |
static String |
getProperty(Properties properties,
String propertyName)
property string and substitutions
|
static String |
getProperty(Properties properties,
String propertyName,
String defaultValue)
property string and substitutions
|
static <T> T |
getProperty(Properties properties,
String propertyName,
T defaultValue,
Function<String,T> function) |
public static String getProperty(Properties properties, String propertyName)
properties - The properties from which to fetch a valuepropertyName - The name of the desired propertycommonSubstitutions(String)public static String getProperty(Properties properties, org.apache.commons.lang3.tuple.Pair<String,String> propertyWithDefaultValue)
public static int getProperty(Properties properties, SimpleIntConfigParameter configParameter)
public static boolean getProperty(Properties properties, SimpleBooleanConfigParameter configParameter)
public static <T> T getProperty(Properties properties, SimpleConfigParameter<T> configParameter, Function<String,T> function)
public static Duration getProperty(Properties properties, SimpleDurationParameter configParameter)
public static <T> T getProperty(Properties properties, String propertyName, T defaultValue, Function<String,T> function)
public static String getProperty(Properties properties, String propertyName, String defaultValue)
properties - The properties from which to fetch a valuepropertyName - The name of the desired propertydefaultValue - The value to use when the propertyName does not existcommonSubstitutions(String)public static String commonSubstitutions(String input)
input - A string with expressions that should be replacedCopyright © 2025 OWASP. All rights reserved.