private String formatDn(String dnPattern, String username, ApiRequest request) {
        Map<String, String> valuesMap = request.getHeaders().toMap();
        valuesMap.put("username", username); //$NON-NLS-1$
        StrSubstitutor sub = new StrSubstitutor(valuesMap);
        return sub.replace(dnPattern);
    }
private String formatDn ( String dnPattern , String username , ApiRequest request ) { Map < String , String > valuesMap = request . getHeaders ( ) . toMap ( ) ; valuesMap . put ( "username" , username ) ; StrSubstitutor sub = new StrSubstitutor ( valuesMap ) ; return sub . replace ( dnPattern ) ; }
Formats the configured DN by replacing any properties it finds.
@param dnPattern
@param username
@param request