LPS-34711 - Allow ${java.home} and ${env:ENV_VAR} as replacements.

The attached contribution is the implementation for request LPS-34711.