forked from I2P_Developers/i2p.i2p
add Closeable/Flushable interfaces
This commit is contained in:
@@ -13,6 +13,7 @@ import java.io.BufferedOutputStream;
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.io.FilenameFilter;
|
||||
import java.io.Flushable;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.io.OutputStream;
|
||||
@@ -193,7 +194,7 @@ class PersistentDataStore extends TransientDataStore {
|
||||
* we will soon have to implement a scheme for keeping only
|
||||
* a subset of all DatabaseEntrys in memory and keeping the rest on disk.
|
||||
*/
|
||||
private class Writer implements Runnable {
|
||||
private class Writer implements Runnable, Flushable {
|
||||
private final Map<Hash, DatabaseEntry>_keys;
|
||||
private final Object _waitLock;
|
||||
private volatile boolean _quit;
|
||||
|
@@ -1,5 +1,6 @@
|
||||
package net.i2p.router.transport.ntcp;
|
||||
|
||||
import java.io.Closeable;
|
||||
import java.io.IOException;
|
||||
import java.net.Inet6Address;
|
||||
import java.nio.ByteBuffer;
|
||||
@@ -64,7 +65,7 @@ import net.i2p.util.VersionComparator;
|
||||
*</pre>
|
||||
*
|
||||
*/
|
||||
class NTCPConnection {
|
||||
class NTCPConnection implements Closeable {
|
||||
private final RouterContext _context;
|
||||
private final Log _log;
|
||||
private SocketChannel _chan;
|
||||
|
Reference in New Issue
Block a user