code: @Override
  	protected void doReplace(final String search, final Writer backing) {
  		WComponent component = componentsByKey.get(search);
  		UIContextHolder.pushContext(uic);
  
  		try {
  			component.paint(new WebXmlRenderContext((PrintWriter) backing));
  		} finally {
  			UIContextHolder.popContext();
  		}
  	}
docs: Replaces the search string by rendering the corresponding component.
  
  @param search the search String that was matched.
  @param backing the underlying writer to write the replacement to.