Пример #1
0
  @Override
  protected void doProcess(Asset asset, Reader reader, Writer writer) throws Exception {

    try {
      CssCompressor compressor = new CssCompressor(reader);
      compressor.compress(writer, -1);
    } catch (IOException e) {
      LOG.error("YUI compressor can't access to the content of {}", asset.toLog());
      throw DandelionException.wrap(e);
    }
  }
Пример #2
0
 @Override
 protected String doGetContent(
     Asset asset, Map<String, Object> parameters, HttpServletRequest request) {
   return ResourceUtils.getContentFromUrl(request, asset.getProcessedConfigLocation(), true);
 }