Lines Matching +full:- +full:compat
1 //! Compatibility between the `tokio::io` and `futures-io` versions of the
10 /// `tokio::io` and `futures-io` `AsyncRead` and `AsyncWrite` traits.
12 pub struct Compat<T> {
24 fn compat(self) -> Compat<Self> in compat() method
28 Compat::new(self) in compat()
39 fn compat_write(self) -> Compat<Self> in compat_write()
43 Compat::new(self) in compat_write()
54 fn compat(self) -> Compat<Self> in compat() method
58 Compat::new(self) in compat()
69 fn compat_write(self) -> Compat<Self> in compat_write()
73 Compat::new(self) in compat_write()
79 // === impl Compat ===
81 impl<T> Compat<T> { implementation
82 fn new(inner: T) -> Self { in new()
91 pub fn get_ref(&self) -> &T { in get_ref()
97 pub fn get_mut(&mut self) -> &mut T { in get_mut()
102 pub fn into_inner(self) -> T { in into_inner()
107 impl<T> tokio::io::AsyncRead for Compat<T> implementation
115 ) -> Poll<io::Result<()>> { in poll_read()
129 impl<T> futures_io::AsyncRead for Compat<T> implementation
137 ) -> Poll<io::Result<usize>> { in poll_read()
148 impl<T> tokio::io::AsyncBufRead for Compat<T> implementation
155 ) -> Poll<io::Result<&'a [u8]>> { in poll_fill_buf()
164 impl<T> futures_io::AsyncBufRead for Compat<T> implementation
171 ) -> Poll<io::Result<&'a [u8]>> { in poll_fill_buf()
180 impl<T> tokio::io::AsyncWrite for Compat<T> implementation
188 ) -> Poll<io::Result<usize>> { in poll_write()
192 fn poll_flush(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<io::Result<()>> { in poll_flush()
196 fn poll_shutdown(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<io::Result<()>> { in poll_shutdown()
201 impl<T> futures_io::AsyncWrite for Compat<T> implementation
209 ) -> Poll<io::Result<usize>> { in poll_write()
213 fn poll_flush(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<io::Result<()>> { in poll_flush()
217 fn poll_close(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<io::Result<()>> { in poll_close()
222 impl<T: tokio::io::AsyncSeek> futures_io::AsyncSeek for Compat<T> { implementation
227 ) -> Poll<io::Result<u64>> { in poll_seek()
240 impl<T: futures_io::AsyncSeek> tokio::io::AsyncSeek for Compat<T> { implementation
241 fn start_seek(mut self: Pin<&mut Self>, pos: io::SeekFrom) -> io::Result<()> { in start_seek()
246 fn poll_complete(mut self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<io::Result<u64>> { in poll_complete()
264 impl<T: std::os::unix::io::AsRawFd> std::os::unix::io::AsRawFd for Compat<T> { implementation
265 fn as_raw_fd(&self) -> std::os::unix::io::RawFd { in as_raw_fd()
271 impl<T: std::os::windows::io::AsRawHandle> std::os::windows::io::AsRawHandle for Compat<T> { implementation
272 fn as_raw_handle(&self) -> std::os::windows::io::RawHandle { in as_raw_handle()