Package org.apache.commons.lang.text

Examples of org.apache.commons.lang.text.StrSubstitutor.replace()


         */
        @Override
        protected String normalizeURI(String uriref)
        {
            StrSubstitutor substitutor = ((CatalogManager) catalogManager).getStrSubstitutor();
            String resolved = substitutor != null ? substitutor.replace(uriref) : uriref;
            return super.normalizeURI(resolved);
        }
    }
}
View Full Code Here


          .put("hash", job.job().getId().getHash())
          .put("job", job.job().toString())
          .put("containerId", job.statuses().get(host).getContainerId())
          .build()
          );
      log.info("{}", subst.replace(jobDeployedMessageFormat));
    }
  }

  public TemporaryJobBuilder imageFromBuild() {
    final String envPath = getenv("IMAGE_INFO_PATH");
View Full Code Here

        List<String> args = builder.getArgs();

        String[] rawArgs = versionManifest.getMinecraftArguments().split(" +");
        StrSubstitutor substitutor = new StrSubstitutor(getCommandSubstitutions());
        for (String arg : rawArgs) {
            args.add(substitutor.replace(arg));
        }
    }

    /**
     * Add proxy arguments.
View Full Code Here

                {
                    return null;
                }
            }
        }, VARIABLE_START_MARKER, VARIABLE_END_MARKER, StrSubstitutor.DEFAULT_ESCAPE);
        String result = transform.replace(activity.getBaseObjectProperties().get("content"));

        //
        if (!result.isEmpty())
        {
            int startIndex = 0, lastSeenLinebreakInLeadingWhitespace = -1, endIndex = result.length();
View Full Code Here

    {
        ConfigurationInterpolator interp = configuration.getInterpolator();
        StrSubstitutor subst = new StrSubstitutor(interp, prefixMatcher, suffixMatcher,
                StrSubstitutor.DEFAULT_ESCAPE);

        String result = subst.replace(var);

        try
        {
            Expression exp = engine.createExpression(result);
            result = (String) exp.evaluate(createContext());
View Full Code Here

              final StrSubstitutor sub = _strSubstitutor;
              _builder.newLineIfNotEmpty();
              _builder.append("\t");
              _builder.append("\t");
              _builder.append("file=\"");
              String _replace_1 = sub.replace(serviceFile);
              _builder.append(_replace_1, "    ");
              _builder.append("\"");
              _builder.newLineIfNotEmpty();
              _builder.append("\t");
              _builder.append("/>");
View Full Code Here

   
    @Override
    public String getProperty(String key, Map<String, String> variables)
    {
      StrSubstitutor substitutor = new StrSubstitutor(variables);
      key = substitutor.replace(key);
      return getProperty(key);
    }
   
    @Override
    public String getProperty(String key, Map<String, String> variables, String defaultValue)
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.