예제 #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;
 }
예제 #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);
        }
예제 #3
0
 protected SignaledSocketStream(MultiStreamSocket socket, long streamId)
     : base(socket, streamId) => _source.RunContinuationsAsynchronously = true;
예제 #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;
 }
예제 #5
0
 protected SignaledSocketStream(MultiStreamSocket socket, bool bidirectional, bool control)
     : base(socket, bidirectional, control)
 {
 }
예제 #6
0
 protected SignaledSocketStream(MultiStreamSocket socket, long streamId)
     : base(socket, streamId)
 {
 }
예제 #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;
 }
예제 #8
0
 protected SignaledSocketStream(bool bidirectional, MultiStreamSocket socket)
     : base(bidirectional, socket)
 {
 }
예제 #9
0
 protected SignaledSocketStream(long streamId, MultiStreamSocket socket)
     : base(streamId, socket)
 {
 }