public class StringUtils extends Object
| Modifier and Type | Method and Description |
|---|---|
static String |
expandEnvironmentVariables(String string)
Replaces all the occurrences of system environment variables placed between
"${" and "}" with their matching values from the given source
string. |
public static String expandEnvironmentVariables(String string)
"${" and "}" with their matching values from the given source
string.
For example:
StringUtils.expandEnvironmentVariables("${TMPDIR}/file1") = "/tmp/file1"
string - the string to be expanded; null returns nullCopyright © 2022. All rights reserved.