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

net.java.truecommons.shed.Releasable Maven / Gradle / Ivy

There is a newer version: 2.5.0
Show newest version
/*
 * Copyright (C) 2005-2015 Schlichtherle IT Services.
 * All rights reserved. Use is subject to license terms.
 */
package net.java.truecommons.shed;

import edu.umd.cs.findbugs.annotations.CleanupObligation;
import edu.umd.cs.findbugs.annotations.DischargesObligation;

/**
 * A resource which can release itself to its associated {@link Pool}.
 *
 * @param   The type of the exceptions thrown by this releasable.
 * @author Christian Schlichtherle
 */
@CleanupObligation
public interface Releasable {

    /**
     * Releases this resource to its pool.
     *
     * @throws X if releasing the resource fails for any reason.
     */
    @DischargesObligation
    void release() throws X;
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy