code: public synchronized String format(final String pattern, final Object... args) {
  		Map<String, Object> model = Collections.emptyMap();
  		ModelAdaptor modelAdaptor = new ModelAdaptor() {
  
  			@Override
  			public Object getValue(TemplateContext context, Token token, List<String> segments, String expression) {
  				int index = Integer.parseInt(expression) - 1;
  				return args[index];
  			}
  
              @Override
              public Iterable<Object> getIterable(Object value) {
                  return null;
              }
  
              @Override
              public String getSpecialIteratorVariable() {
                  return null;
              }
  
          };
  
  		String output = transformInternal(pattern, null, model, modelAdaptor, null);
  		return output;
  	}
docs: Replacement for {@link java.lang.String#format(String, Object...)}. All arguments will be
  put into the model having their index starting from 1 as their name.
  
  @param pattern
  the template
  @param args
  any number of arguments
  @return the expanded template