class IntermediatePathComposer {

    public String retrieveIntermediatePath(LaunchDataWrapper launchDataWrapper, ParamsMap paramsMap, String defaultIntermediatePath)
    {
        if(paramsMap != null)
        {
            String intermediatePath = paramsMap.getString(INTERMEDIATE_PATH_KEY, null);
            if(StringUtils.isNotBlank(intermediatePath))
            {
                validateIntermediatePath(
                    intermediatePath,
                    launchDataWrapper.getPropertyRetriever().getField(INTERMEDIATE_REQUIRED_PATH_TOKENS_KEY, null),
                    launchDataWrapper);
                return intermediatePath;
            }
        }
        return defaultIntermediatePath;
    }

    public  IntermediatePathComposer();

}