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 org.apache.arrow.vector.file.json.JsonFileWriter.java

public class JsonFileWriter implements AutoCloseable {

    public static final class JSONWriteConfig {
        private final boolean pretty;

        private JSONWriteConfig(boolean pretty) {

From source file org.eclipse.jgit.transport.http.apache.TemporaryBufferEntity.java

/**
 * A {@link HttpEntity} which takes it's content from a {@link TemporaryBuffer}
 *
 * @since 3.3
 */
public class TemporaryBufferEntity extends AbstractHttpEntity implements AutoCloseable {

From source file at.ac.univie.isc.asio.web.HttpServer.java

/**
 * Provide a lightweight, embedded {@link com.sun.net.httpserver.HttpServer http server} listening
 * to a random, free port on localhost.
 */
public final class HttpServer extends ExternalResource implements Interactions.Report, AutoCloseable {

From source file ezbake.amino.cli.Main.java

public class Main implements Callable<Integer>, AutoCloseable {
    private static final String DN = "CN=Smith, Joe, OU=People, OU=EzBake, OU=CSC, O=Foo, C=US";
    private static final Set<String> AUTHORIZATIONS = Sets.newHashSet("U");
    static final Logger logger = LoggerFactory.getLogger(Main.class);

    @Option(name = "--use-mock-security", usage = "Use a mock security token", required = false)

From source file org.exist.xmldb.RemoteResourceSet.java

public class RemoteResourceSet implements ResourceSet, AutoCloseable {

    private final Leasable<XmlRpcClient> leasableXmlRpcClient;
    private final XmlRpcClient xmlRpcClient;
    private final RemoteCollection collection;
    private int handle = -1;

From source file org.apache.storm.daemon.DrpcServer.java

public class DrpcServer implements DistributedRPC.Iface, DistributedRPCInvocations.Iface, AutoCloseable {

    private static final Logger LOG = LoggerFactory.getLogger(DrpcServer.class);
    private final Long timeoutCheckSecs = 5L;

    private Map conf;

From source file io.mandrel.transport.thrift.KeyedClientPool.java

@Data
public class KeyedClientPool<T extends Contract & AutoCloseable> implements AutoCloseable {

    private static int DEFAULT_PORT = 9090;
    private static Integer DEFAULT_DEFLATE_LEVEL = Integer.valueOf(Deflater.BEST_SPEED);

From source file sf.net.experimaestro.manager.scripting.ScriptContext.java

/**
 * Context when running a script
 * <p/>
 * This class hides away what is part of the static context and
 * what if part of the dynamic one
 */

From source file org.apache.pulsar.PulsarStandalone.java

public class PulsarStandalone implements AutoCloseable {

    private static final Logger log = LoggerFactory.getLogger(PulsarStandalone.class);

    PulsarService broker;
    PulsarAdmin admin;

From source file org.opendaylight.netvirt.dhcpservice.DhcpUCastMacListener.java

public class DhcpUCastMacListener extends
        AsyncClusteredDataTreeChangeListenerBase<LocalUcastMacs, DhcpUCastMacListener> implements AutoCloseable {

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

    private final DhcpExternalTunnelManager dhcpExternalTunnelManager;