All Downloads are FREE. Search and download functionalities are using the official Maven repository.

nl.topicus.jdbc.shaded.com.google.instrumentation.common.NonThrowingCloseable Maven / Gradle / Ivy

There is a newer version: 1.1.6
Show newest version
package nl.topicus.jdbc.shaded.com.google.instrumentation.common;

import java.io.Closeable;

/**
 * An {@link Closeable} which cannot throw a checked exception.
 *
 * 

This is useful because such a reversion otherwise requires the caller to catch the * (impossible) Exception in the try-with-resources. * *

Example of usage: * *

 *   try (NonThrowingAutoCloseable ctx = tryEnter()) {
 *     ...
 *   }
 * 
*/ public interface NonThrowingCloseable extends Closeable { @Override void close(); }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy