private void executeMinify() {

    Minifier minifier = findMinifier();

    InputStream inStream = null;
    OutputStream outStream = null;
    try {
      inStream = this.fileIn != null ? Streams.fileInputStream(this.fileIn) : null;
      outStream = this.fileOut != null ? Streams.fileOutputStream(this.fileOut) : null;

      minifier.minify(inStream, outStream, this.commentCharset, this.comment);
    } finally {
      Streams.close(inStream);
      Streams.close(outStream);
    }
  }
 private Minifier minifierForFile(File file) {
   checkNotNull(file);
   return Minifier.forFileName(file.getName());
 }
 private Minifier minifierForFormat(Format format) {
   return Minifier.forFileName("file." + format.name().toLowerCase());
 }