public final class Closer extends Object
| Constructor and Description | 
|---|
| Closer() | 
| Modifier and Type | Method and Description | 
|---|---|
| static void | close(Closeable closeable)Closes the given Closeable in a null-safe manner. | 
| static void | close(ModalCloseable closeable,
     CloseMode closeMode)Closes the given Closeable in a null-safe manner. | 
| static void | closeQuietly(Closeable closeable)Closes the given Closeable quietly in a null-safe manner even in the event of an exception. | 
public static void close(Closeable closeable) throws IOException
closeable - what to close.IOExceptionpublic static void close(ModalCloseable closeable, CloseMode closeMode)
closeable - what to close.closeMode - How to close the given resource.public static void closeQuietly(Closeable closeable)
closeable - what to close.Copyright © 2005–2021 The Apache Software Foundation. All rights reserved.