Package juzu.impl.asset

Examples of juzu.impl.asset.NormalizeJSReader


      }

      if (idx != -1) {
        buffer.append(adapter.substring(0, idx)).append("\n");
      }
      Tools.copy(new NormalizeJSReader(new InputStreamReader(stream)), buffer);
      if (idx != -1) {
        buffer.append(adapter.substring(idx + "@{include}".length(), adapter.length()));
      }

      //
View Full Code Here


public class NormalizeJSMinifier implements Minifier {

  @Override
  public InputStream minify(String name, String type, InputStream stream) throws IOException {
    if (type.equals("script")) {
      NormalizeJSReader reader = new NormalizeJSReader(new InputStreamReader(stream));
      String s = Tools.read(reader);
      return new ByteArrayInputStream(s.getBytes());
    } else {
      throw new IOException("Can only process scripts and not " + type + " asset");
    }
View Full Code Here

TOP

Related Classes of juzu.impl.asset.NormalizeJSReader

Copyright © 2018 www.massapicom. 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.