pub struct FidlIoConnection<T: 'static + File> { /* private fields */ }
Expand description
Wrapper around a file that manages the seek offset of the connection and transforms IoOpHandler
requests into FileIo
requests. All File
requests are forwarded to file
.
Implementations§
Source§impl<T: 'static + File + FileIo> FidlIoConnection<T>
impl<T: 'static + File + FileIo> FidlIoConnection<T>
Sourcepub fn create(
scope: ExecutionScope,
file: Arc<T>,
options: impl ToFileOptions,
object_request: ObjectRequestRef<'_>,
) -> Result<impl Future<Output = ()>, Status>
pub fn create( scope: ExecutionScope, file: Arc<T>, options: impl ToFileOptions, object_request: ObjectRequestRef<'_>, ) -> Result<impl Future<Output = ()>, Status>
Creates a connection to a file that uses FIDL for all IO.
Sourcepub fn spawn(
scope: ExecutionScope,
file: Arc<T>,
options: FileOptions,
object_request: ObjectRequestRef<'_>,
) -> Result<(), Status>
pub fn spawn( scope: ExecutionScope, file: Arc<T>, options: FileOptions, object_request: ObjectRequestRef<'_>, ) -> Result<(), Status>
Like create, but spawns a task to run the connection.
Trait Implementations§
Source§impl<T: 'static + File> Deref for FidlIoConnection<T>
impl<T: 'static + File> Deref for FidlIoConnection<T>
Auto Trait Implementations§
impl<T> Freeze for FidlIoConnection<T>
impl<T> RefUnwindSafe for FidlIoConnection<T>where
T: RefUnwindSafe,
impl<T> Send for FidlIoConnection<T>
impl<T> Sync for FidlIoConnection<T>
impl<T> Unpin for FidlIoConnection<T>
impl<T> UnwindSafe for FidlIoConnection<T>where
T: RefUnwindSafe,
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