Here you can find the source of closeIgnoringExceptions(Closeable c)
Parameter | Description |
---|---|
c | the closeable |
public static final void closeIgnoringExceptions(Closeable c)
//package com.java2s; //License from project: Open Source License import java.io.Closeable; public class Main { /**//w w w . j a v a2s . c o m * Helper method use to close a {@link Closeable} ignoring eventual exception * * @param c * the closeable */ public static final void closeIgnoringExceptions(Closeable c) { try { if (c != null) { c.close(); } } catch (Throwable _) { } } }