Example usage for java.lang AutoCloseable interface-usage

List of usage examples for java.lang AutoCloseable interface-usage

Introduction

In this page you can find the example usage for java.lang AutoCloseable interface-usage.

Usage

From source file com.hortonworks.streamline.streams.catalog.service.metadata.KafkaMetadataService.java

/**
 * This class opens zookeeper client connections which must be closed either by calling the {@link KafkaMetadataService#close()}'
 * method on a finally block, or instantiating this class in a try with resources statement.
 */
public class KafkaMetadataService implements AutoCloseable {
    public static final String STREAMS_JSON_SCHEMA_SERVICE_KAFKA = ServiceConfigurations.KAFKA.name();

From source file onl.area51.httpd.action.Request.java

/**
 *
 * @author peter
 */
public interface Request extends AutoCloseable {

From source file com.linkedin.pinot.core.segment.index.loader.SegmentPreProcessor.java

/**
 * mmap()'s the segment and performs any pre-processing to generate inverted index
 * This can be slow
 */
public class SegmentPreProcessor implements AutoCloseable {
    private static Logger LOGGER = LoggerFactory.getLogger(SegmentPreProcessor.class);

From source file kina.cql.CqlRecordWriter.java

/**
 * Handles the distributed write to cassandra in batch.
 */
public class CqlRecordWriter implements AutoCloseable {

    private static final Logger LOG = LoggerFactory.getLogger(CqlRecordWriter.class);

From source file com.spotify.helios.serviceregistration.skydns.MiniEtcdClient.java

/**
 * A minimal etcd client usable for our purposes for SkyDNS
 *
 * TODO: Support multiple etcd servers.
 */
class MiniEtcdClient implements AutoCloseable {

From source file org.eclipse.packagedrone.utils.deb.build.DebianPackageWriter.java

public class DebianPackageWriter implements AutoCloseable, BinaryPackageBuilder {
    public static final Charset CHARSET = Charset.forName("UTF-8");

    private final ArArchiveOutputStream ar;

    private final byte[] binaryHeader = "2.0\n".getBytes();

From source file org.apache.storm.daemon.logviewer.LogviewerServer.java

/**
 * The main entry of Logviewer.
 */
public class LogviewerServer implements AutoCloseable {
    private static final Logger LOG = LoggerFactory.getLogger(LogviewerServer.class);
    private static final String stormHome = System.getProperty(ConfigUtils.STORM_HOME);

From source file org.opendaylight.vtn.manager.internal.VTNManagerProvider.java

/**
 * This interface defines an internal OSGi service which provides MD-SAL
 * VTN Manager services used by AD-SAL interface.
 */
public interface VTNManagerProvider extends AutoCloseable, Executor, TxQueue, FlowRpcWatcher {
    /**

From source file org.eclipse.scada.utils.pkg.deb.DebianPackageWriter.java

public class DebianPackageWriter implements AutoCloseable, BinaryPackageBuilder {
    private static final int AR_ARCHIVE_DEFAULT_MODE = 33188; // unfortunately this is not a public field of ArArchiveEntry

    public static final Charset CHARSET = Charset.forName("UTF-8");

    private final ArArchiveOutputStream ar;

From source file cn.edu.wyu.documentviewer.DirectoryResult.java

class DirectoryResult implements AutoCloseable {
    ContentProviderClient client;
    Cursor cursor;
    Exception exception;

    int mode = MODE_UNKNOWN;