Beispiel #1
0
 /// <summary>Constructs a stream with the given ID.</summary>
 /// <param name="streamId">The stream ID.</param>
 /// <param name="socket">The parent socket.</param>
 protected SocketStream(long streamId, MultiStreamSocket socket)
 {
     _socket = socket;
     _id     = streamId;
     _socket.AddStream(_id, this);
     IsBidirectional = _id % 4 < 2;
 }
Beispiel #2
0
        /// <summary>Constructs a stream with the given ID.</summary>
        /// <param name="streamId">The stream ID.</param>
        /// <param name="socket">The parent socket.</param>
        protected SocketStream(MultiStreamSocket socket, long streamId)
        {
            _socket         = socket;
            _id             = streamId;
            IsBidirectional = _id % 4 < 2;
            IsControl       = _id == 2 || _id == 3;

            _socket.AddStream(_id, this, IsControl);
        }
Beispiel #3
0
 protected SignaledSocketStream(MultiStreamSocket socket, long streamId)
     : base(socket, streamId) => _source.RunContinuationsAsynchronously = true;
Beispiel #4
0
 /// <summary>Constructs an outgoing stream.</summary>
 /// <param name="bidirectional">True to create a bidirectional stream, False otherwise.</param>
 /// <param name="control">True to create a control stream, False otherwise.</param>
 /// <param name="socket">The parent socket.</param>
 protected SocketStream(MultiStreamSocket socket, bool bidirectional, bool control)
 {
     _socket         = socket;
     IsBidirectional = bidirectional;
     IsControl       = control;
 }
Beispiel #5
0
 protected SignaledSocketStream(MultiStreamSocket socket, bool bidirectional, bool control)
     : base(socket, bidirectional, control)
 {
 }
Beispiel #6
0
 protected SignaledSocketStream(MultiStreamSocket socket, long streamId)
     : base(socket, streamId)
 {
 }
Beispiel #7
0
 /// <summary>Constructs an outgoing stream.</summary>
 /// <param name="bidirectional">True to create a bidirectional, False otherwise.</param>
 /// <param name="socket">The parent socket.</param>
 protected SocketStream(bool bidirectional, MultiStreamSocket socket)
 {
     IsBidirectional = bidirectional;
     _socket         = socket;
 }
Beispiel #8
0
 protected SignaledSocketStream(bool bidirectional, MultiStreamSocket socket)
     : base(bidirectional, socket)
 {
 }
Beispiel #9
0
 protected SignaledSocketStream(long streamId, MultiStreamSocket socket)
     : base(streamId, socket)
 {
 }