Much work
This commit is contained in:
		| @@ -0,0 +1,27 @@ | ||||
| use super::*; | ||||
|  | ||||
| #[derive(Debug)] | ||||
| pub(super) struct Stream<B> { | ||||
|     /// Current state of the stream | ||||
|     pub state: State, | ||||
|  | ||||
|     /// Frames pending for this stream being sent to the socket | ||||
|     pub pending_send: buffer::Deque<B>, | ||||
| } | ||||
|  | ||||
| impl<B> Stream<B> { | ||||
|     pub fn new() -> Stream<B> { | ||||
|         Stream { | ||||
|             state: State::default(), | ||||
|             pending_send: buffer::Deque::new(), | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     pub fn send_flow_control(&mut self) -> Option<&mut FlowControl> { | ||||
|         self.state.send_flow_control() | ||||
|     } | ||||
|  | ||||
|     pub fn recv_flow_control(&mut self) -> Option<&mut FlowControl> { | ||||
|         self.state.recv_flow_control() | ||||
|     } | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user