org.crsh.util
Class CloseableList
java.lang.Object
org.crsh.util.CloseableList
- All Implemented Interfaces:
- Closeable
public final class CloseableList
- extends Object
- implements Closeable
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
log
final Logger log
- .
closeables
private final ArrayList<Closeable> closeables
- .
closed
private final AtomicBoolean closed
- .
CloseableList
public CloseableList()
isClosed
public boolean isClosed()
add
public void add(Closeable closeable)
throws IllegalStateException,
NullPointerException
- Add a closeable to the list.
- Parameters:
closeable
- the closeable to add
- Throws:
IllegalStateException
- if the list is already closed
NullPointerException
- if the argument is null
close
public void close()
- Specified by:
close
in interface Closeable
Copyright © 2014 eXo Platform SAS. All Rights Reserved.