pub struct DirHandler { /* private fields */ }Expand description
Handler that serves read requests for a directory.
Implementations§
Source§impl DirHandler
impl DirHandler
Trait Implementations§
Source§impl Handler for DirHandler
impl Handler for DirHandler
type Reader = Unblock<File>
type Writer = Unblock<File>
Source§async fn read_req_open(
&mut self,
_client: &SocketAddr,
path: &Path,
) -> Result<(Self::Reader, Option<u64>), Error>
async fn read_req_open( &mut self, _client: &SocketAddr, path: &Path, ) -> Result<(Self::Reader, Option<u64>), Error>
Open
Reader to serve a read request.Source§async fn write_req_open(
&mut self,
_client: &SocketAddr,
path: &Path,
size: Option<u64>,
) -> Result<Self::Writer, Error>
async fn write_req_open( &mut self, _client: &SocketAddr, path: &Path, size: Option<u64>, ) -> Result<Self::Writer, Error>
Open
Writer to serve a write request.Auto Trait Implementations§
impl Freeze for DirHandler
impl RefUnwindSafe for DirHandler
impl Send for DirHandler
impl Sync for DirHandler
impl Unpin for DirHandler
impl UnwindSafe for DirHandler
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more