mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-13 03:09:04 +01:00
Factory methods for segmented connection writers.
This commit is contained in:
@@ -2,20 +2,21 @@ package net.sf.briar.api.transport;
|
||||
|
||||
import java.io.OutputStream;
|
||||
|
||||
import net.sf.briar.api.plugins.SegmentSink;
|
||||
|
||||
public interface ConnectionWriterFactory {
|
||||
|
||||
/**
|
||||
* Creates a connection writer for a simplex connection or the initiator's
|
||||
* side of a duplex connection. The secret is erased before this method
|
||||
* returns.
|
||||
* Creates a connection writer for a simplex connection or one side of a
|
||||
* duplex connection. The secret is erased before this method returns.
|
||||
*/
|
||||
ConnectionWriter createConnectionWriter(OutputStream out, long capacity,
|
||||
byte[] secret);
|
||||
byte[] secret, boolean initiator);
|
||||
|
||||
/**
|
||||
* Creates a connection writer for the responder's side of a duplex
|
||||
* connection. The secret is erased before this method returns.
|
||||
* Creates a connection writer for a simplex connection or one side of a
|
||||
* duplex connection. The secret is erased before this method returns.
|
||||
*/
|
||||
ConnectionWriter createConnectionWriter(OutputStream out, long capacity,
|
||||
byte[] secret, byte[] tag);
|
||||
ConnectionWriter createConnectionWriter(SegmentSink out, long capacity,
|
||||
byte[] secret, boolean initiator);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user