Package org.msyu.javautil.exceptions
Interface ParameterizedAutoCloseable<X extends java.lang.Exception>
-
- All Superinterfaces:
java.lang.AutoCloseable
public interface ParameterizedAutoCloseable<X extends java.lang.Exception> extends java.lang.AutoCloseable
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfaceParameterizedAutoCloseable.Locks
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Modifier and Type Method Description voidclose()static <T,C extends java.lang.Exception,D extends java.lang.Exception>
ParameterizedAutoCloseable<D>wrap(T object, ConsumerWithException<? super T,C> ctor, ConsumerWithException<? super T,D> dtor)static <T,X extends java.lang.Exception>
ParameterizedAutoCloseable<X>wrap(T object, ConsumerWithException<? super T,X> destructor)
-
-
-
Method Detail
-
close
void close() throws X extends java.lang.Exception- Specified by:
closein interfacejava.lang.AutoCloseable- Throws:
X extends java.lang.Exception
-
wrap
static <T,X extends java.lang.Exception> ParameterizedAutoCloseable<X> wrap(T object, ConsumerWithException<? super T,X> destructor)
-
wrap
static <T,C extends java.lang.Exception,D extends java.lang.Exception> ParameterizedAutoCloseable<D> wrap(T object, ConsumerWithException<? super T,C> ctor, ConsumerWithException<? super T,D> dtor) throws C extends java.lang.Exception
- Throws:
C extends java.lang.Exception
-
-