Java Stream Close closeEntry(ZipOutputStream... outputStreams)

Here you can find the source of closeEntry(ZipOutputStream... outputStreams)

Description

Equivalent to ZipOutputStream#closeEntry() but without checked exception.

License

Apache License

Declaration

public static void closeEntry(ZipOutputStream... outputStreams) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

import java.io.IOException;

import java.util.zip.ZipOutputStream;

public class Main {
    /**//w  w w .  j  a v a 2s .co m
     * Equivalent to {@link ZipOutputStream#closeEntry()} but without checked
     * exception.
     */
    public static void closeEntry(ZipOutputStream... outputStreams) {
        for (final ZipOutputStream outputStream : outputStreams) {
            try {
                outputStream.closeEntry();
            } catch (final IOException e) {
                throw new RuntimeException(e);
            }
        }
    }
}

Related

  1. closeCloseableIfNotNull(Closeable fileWriter)
  2. closeConnection(Closeable... closes)
  3. closeDataLine(final SourceDataLine line, final AudioInputStream ais)
  4. closeDebugFile()
  5. closeEL(InputStream is)
  6. closeFile()
  7. closeFile()
  8. closeFile(File file, boolean toBeDeleted)
  9. closeFile(File file, RandomAccessFile raf)