Uses of Class
de.xima.fc.common.auto_closeable.AutoCloseableWrapper
-
Packages that use AutoCloseableWrapper Package Description de.xima.fc.common.auto_closeable -
-
Uses of AutoCloseableWrapper in de.xima.fc.common.auto_closeable
Methods in de.xima.fc.common.auto_closeable that return AutoCloseableWrapper Modifier and Type Method Description static <T> AutoCloseableWrapper<T,Exception>AutoCloseableWrapper. ofObject(T wrapped)Creates a wrapper for the given object that will close the object when closed, if the object implementsAutoCloseable; and do nothing otherwise.static <T> AutoCloseableWrapper<T,RuntimeException>AutoCloseableWrapper. ofObjectQuiet(T wrapped)Creates a wrapper for the given object that will close the object when closed, if the object implementsAutoCloseable; and do nothing otherwise.static <T,E extends Exception>
AutoCloseableWrapper<T,E>AutoCloseableWrapper. withCloseAction(T wrapped, ITypedThrowingConsumer<? super T,? extends E> close)Creates a wrapper for the given object that will call the given close action when closed.
-