public interface CloseableConsumer
This provides a way to close said resources in the calling code.
| Modifier and Type | Field and Description |
|---|---|
static CloseableConsumer |
CLOSING_CONSUMER
Closes the passed in Closeable immediately.
|
static CloseableConsumer |
NULL_CONSUMER
Completely ignores the passed in Closeable.
|
| Modifier and Type | Method and Description |
|---|---|
void |
accept(Closeable c)
Callback that is informed about a closable resource that has
been wrapped around a passed in stream or channel by Expander
or Archiver when Expander or Archiver no longer need them.
|
static final CloseableConsumer CLOSING_CONSUMER
static final CloseableConsumer NULL_CONSUMER
void accept(Closeable c) throws IOException
c - Closeable created by Expander or Archiver that is now
no longer usedIOException - on errorCopyright © 2020 The Apache Software Foundation. All rights reserved.