Java Stream Close closeStreamIgnoreExpection(InputStream stream)

Here you can find the source of closeStreamIgnoreExpection(InputStream stream)

Description

close Stream Ignore Expection

License

Open Source License

Declaration

public static void closeStreamIgnoreExpection(InputStream stream) 

Method Source Code

//package com.java2s;

import java.io.InputStream;

public class Main {

    public static void closeStreamIgnoreExpection(InputStream stream) {
        try {//from w  ww . ja va  2s  . co m
            if (stream != null) {
                stream.close();
            }
        } catch (Exception e) {
            // do nothing here
        }
    }
}

Related

  1. closeStream(InputStream in)
  2. closeStream(InputStream inputStream)
  3. closeStream(InputStream ins)
  4. closeStream(Object oin)
  5. closeStream(OutputStream os)
  6. closeStreamQuietly(final Closeable closeable)
  7. closeStreams(FileInputStream fis, FileOutputStream fos)
  8. closeStreams(InputStream iStream, OutputStream oStream)
  9. closeStreams(InputStream src, OutputStream dest)