pub trait FsProvider: Send + Sync {
Show 37 associated items type LookupFut<'c>: Send + Future<Output = Result<LookupReply>> where Self: 'c; type CreateFut<'c>: Send + Future<Output = Result<CreateReply>> where Self: 'c; type OpenFut<'c>: Send + Future<Output = Result<OpenReply>> where Self: 'c; type ReadGuard: Send + Sync + Deref<Target = [u8]>; type ReadFut<'c>: Send + Future<Output = Result<Self::ReadGuard>> where Self: 'c; type WriteFut<'r>: Send + Future<Output = Result<WriteReply>> where Self: 'r; type FlushFut<'c>: Send + Future<Output = Result<()>> where Self: 'c; type ReadDirFut<'c>: Send + Future<Output = Result<ReadDirReply>> where Self: 'c; type LinkFut<'c>: Send + Future<Output = Result<LinkReply>> where Self: 'c; type UnlinkFut<'c>: Send + Future<Output = Result<()>> where Self: 'c; type ReadMetaFut<'c>: Send + Future<Output = Result<ReadMetaReply>> where Self: 'c; type WriteMetaFut<'c>: Send + Future<Output = Result<WriteMetaReply>> where Self: 'c; type AllocateFut<'c>: Send + Future<Output = Result<()>> where Self: 'c; type CloseFut<'c>: Send + Future<Output = Result<()>> where Self: 'c; type ForgetFut<'c>: Send + Future<Output = Result<()>> where Self: 'c; type LockFut<'c>: Send + Future<Output = Result<()>> where Self: 'c; type UnlockFut<'c>: Send + Future<Output = Result<()>> where Self: 'c; type AddReacapFut<'c>: Send + Future<Output = Result<()>> where Self: 'c; type GrantAccessFut<'c>: Send + Future<Output = Result<()>> where Self: 'c; // Required methods fn lookup<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Lookup<'c> ) -> Self::LookupFut<'c>; fn create<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Create<'c> ) -> Self::CreateFut<'c>; fn open<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Open ) -> Self::OpenFut<'c>; fn read<'c>( &'c self, from: &'c Arc<BlockPath>, msg: ReadMsg ) -> Self::ReadFut<'c>; fn write<'c>( &'c self, from: &'c Arc<BlockPath>, write: Write<&'c [u8]> ) -> Self::WriteFut<'c>; fn flush<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Flush ) -> Self::FlushFut<'c>; fn read_dir<'c>( &'c self, from: &'c Arc<BlockPath>, msg: ReadDir ) -> Self::ReadDirFut<'c>; fn link<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Link<'c> ) -> Self::LinkFut<'c>; fn unlink<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Unlink<'c> ) -> Self::UnlinkFut<'c>; fn read_meta<'c>( &'c self, from: &'c Arc<BlockPath>, msg: ReadMeta ) -> Self::ReadMetaFut<'c>; fn write_meta<'c>( &'c self, from: &'c Arc<BlockPath>, msg: WriteMeta ) -> Self::WriteMetaFut<'c>; fn allocate<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Allocate ) -> Self::AllocateFut<'c>; fn close<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Close ) -> Self::CloseFut<'c>; fn forget<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Forget ) -> Self::ForgetFut<'c>; fn lock<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Lock ) -> Self::LockFut<'c>; fn unlock<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Unlock ) -> Self::UnlockFut<'c>; fn add_readcap<'c>( &'c self, from: &'c Arc<BlockPath>, msg: AddReadcap ) -> Self::AddReacapFut<'c>; fn grant_access<'c>( &'c self, from: &'c Arc<BlockPath>, msg: GrantAccess ) -> Self::GrantAccessFut<'c>;
}
Expand description

Trait for types which act as filesystem servers.

Required Associated Types§

source

type LookupFut<'c>: Send + Future<Output = Result<LookupReply>> where Self: 'c

source

type CreateFut<'c>: Send + Future<Output = Result<CreateReply>> where Self: 'c

source

type OpenFut<'c>: Send + Future<Output = Result<OpenReply>> where Self: 'c

source

type ReadGuard: Send + Sync + Deref<Target = [u8]>

source

type ReadFut<'c>: Send + Future<Output = Result<Self::ReadGuard>> where Self: 'c

source

type WriteFut<'r>: Send + Future<Output = Result<WriteReply>> where Self: 'r

source

type FlushFut<'c>: Send + Future<Output = Result<()>> where Self: 'c

source

type ReadDirFut<'c>: Send + Future<Output = Result<ReadDirReply>> where Self: 'c

source

type LinkFut<'c>: Send + Future<Output = Result<LinkReply>> where Self: 'c

source

type UnlinkFut<'c>: Send + Future<Output = Result<()>> where Self: 'c

source

type ReadMetaFut<'c>: Send + Future<Output = Result<ReadMetaReply>> where Self: 'c

source

type WriteMetaFut<'c>: Send + Future<Output = Result<WriteMetaReply>> where Self: 'c

source

type AllocateFut<'c>: Send + Future<Output = Result<()>> where Self: 'c

source

type CloseFut<'c>: Send + Future<Output = Result<()>> where Self: 'c

source

type ForgetFut<'c>: Send + Future<Output = Result<()>> where Self: 'c

source

type LockFut<'c>: Send + Future<Output = Result<()>> where Self: 'c

source

type UnlockFut<'c>: Send + Future<Output = Result<()>> where Self: 'c

source

type AddReacapFut<'c>: Send + Future<Output = Result<()>> where Self: 'c

source

type GrantAccessFut<'c>: Send + Future<Output = Result<()>> where Self: 'c

Required Methods§

source

fn lookup<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Lookup<'c> ) -> Self::LookupFut<'c>

source

fn create<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Create<'c> ) -> Self::CreateFut<'c>

source

fn open<'c>(&'c self, from: &'c Arc<BlockPath>, msg: Open) -> Self::OpenFut<'c>

source

fn read<'c>( &'c self, from: &'c Arc<BlockPath>, msg: ReadMsg ) -> Self::ReadFut<'c>

Reads from the file specified in the given message.

WARNING

The returned guard must be dropped before another method is called on this provider. Otherwise deadlock will occur.

source

fn write<'c>( &'c self, from: &'c Arc<BlockPath>, write: Write<&'c [u8]> ) -> Self::WriteFut<'c>

source

fn flush<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Flush ) -> Self::FlushFut<'c>

source

fn read_dir<'c>( &'c self, from: &'c Arc<BlockPath>, msg: ReadDir ) -> Self::ReadDirFut<'c>

source

fn read_meta<'c>( &'c self, from: &'c Arc<BlockPath>, msg: ReadMeta ) -> Self::ReadMetaFut<'c>

source

fn write_meta<'c>( &'c self, from: &'c Arc<BlockPath>, msg: WriteMeta ) -> Self::WriteMetaFut<'c>

source

fn allocate<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Allocate ) -> Self::AllocateFut<'c>

source

fn close<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Close ) -> Self::CloseFut<'c>

source

fn forget<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Forget ) -> Self::ForgetFut<'c>

source

fn lock<'c>(&'c self, from: &'c Arc<BlockPath>, msg: Lock) -> Self::LockFut<'c>

source

fn unlock<'c>( &'c self, from: &'c Arc<BlockPath>, msg: Unlock ) -> Self::UnlockFut<'c>

source

fn add_readcap<'c>( &'c self, from: &'c Arc<BlockPath>, msg: AddReadcap ) -> Self::AddReacapFut<'c>

source

fn grant_access<'c>( &'c self, from: &'c Arc<BlockPath>, msg: GrantAccess ) -> Self::GrantAccessFut<'c>

Implementors§

source§

impl FsProvider for FsClient

§

type LookupFut<'c> = impl Send + Future<Output = Result<LookupReply, Error>> + 'c

§

type CreateFut<'c> = impl Send + Future<Output = Result<CreateReply, Error>> + 'c

§

type OpenFut<'c> = impl Send + Future<Output = Result<OpenReply, Error>> + 'c

§

type ReadGuard = Vec<u8, Global>

§

type ReadFut<'c> = impl Send + Future<Output = Result<<FsClient as FsProvider>::ReadGuard, Error>> + 'c

§

type WriteFut<'r> = impl Send + Future<Output = Result<WriteReply, Error>> + 'r

§

type FlushFut<'c> = impl Send + Future<Output = Result<(), Error>> + 'c

§

type ReadDirFut<'c> = impl Send + Future<Output = Result<ReadDirReply, Error>> + 'c

§

type LinkFut<'c> = impl Send + Future<Output = Result<LinkReply, Error>> + 'c

§

type UnlinkFut<'c> = impl Send + Future<Output = Result<(), Error>> + 'c

§

type ReadMetaFut<'c> = impl Send + Future<Output = Result<ReadMetaReply, Error>> + 'c

§

type WriteMetaFut<'c> = impl Send + Future<Output = Result<WriteMetaReply, Error>> + 'c

§

type AllocateFut<'c> = impl Send + Future<Output = Result<(), Error>> + 'c

§

type CloseFut<'c> = impl Send + Future<Output = Result<(), Error>> + 'c

§

type ForgetFut<'c> = impl Send + Future<Output = Result<(), Error>> + 'c

§

type LockFut<'c> = impl Send + Future<Output = Result<(), Error>> + 'c

§

type UnlockFut<'c> = impl Send + Future<Output = Result<(), Error>> + 'c

§

type AddReacapFut<'c> = impl Send + Future<Output = Result<(), Error>> + 'c

§

type GrantAccessFut<'c> = impl Send + Future<Output = Result<(), Error>> + 'c

source§

impl<A: 'static + Authorizer + Send + Sync> FsProvider for LocalFs<A>

§

type LookupFut<'c> = impl Send + Future<Output = Result<LookupReply, Error>> + 'c

§

type CreateFut<'c> = impl Send + Future<Output = Result<CreateReply, Error>> + 'c

§

type OpenFut<'c> = impl Send + Future<Output = Result<OpenReply, Error>> + 'c

§

type ReadGuard = BufGuard

§

type ReadFut<'c> = impl Send + Future<Output = Result<<LocalFs<A> as FsProvider>::ReadGuard, Error>> + 'c

§

type WriteFut<'r> = impl Send + Future<Output = Result<WriteReply, Error>> + 'r

§

type FlushFut<'c> = impl Send + Future<Output = Result<(), Error>> + 'c

§

type ReadDirFut<'c> = impl Send + Future<Output = Result<ReadDirReply, Error>> + 'c

§

type LinkFut<'c> = impl Send + Future<Output = Result<LinkReply, Error>> + 'c

§

type UnlinkFut<'c> = impl Send + Future<Output = Result<(), Error>> + 'c

§

type ReadMetaFut<'c> = impl Send + Future<Output = Result<ReadMetaReply, Error>> + 'c

§

type WriteMetaFut<'c> = impl Send + Future<Output = Result<WriteMetaReply, Error>> + 'c

§

type AllocateFut<'c> = impl Send + Future<Output = Result<(), Error>> + 'c

§

type CloseFut<'c> = impl Send + Future<Output = Result<(), Error>> + 'c

§

type ForgetFut<'c> = impl Send + Future<Output = Result<(), Error>> + 'c

§

type LockFut<'c> = Ready<Result<(), Error>>

§

type UnlockFut<'c> = Ready<Result<(), Error>>

§

type AddReacapFut<'c> = impl Send + Future<Output = Result<(), Error>> + 'c

§

type GrantAccessFut<'c> = impl Send + Future<Output = Result<(), Error>> + 'c

source§

impl<P: 'static + ?Sized + FsProvider, Ptr: Send + Sync + Deref<Target = P>> FsProvider for Ptr

§

type LookupFut<'c> where Self: 'c = <P as FsProvider>::LookupFut<'c>

§

type CreateFut<'c> where Self: 'c = <P as FsProvider>::CreateFut<'c>

§

type OpenFut<'c> where Self: 'c = <P as FsProvider>::OpenFut<'c>

§

type ReadGuard = <P as FsProvider>::ReadGuard

§

type ReadFut<'c> where Self: 'c = <P as FsProvider>::ReadFut<'c>

§

type WriteFut<'r> where Self: 'r = <P as FsProvider>::WriteFut<'r>

§

type FlushFut<'c> where Self: 'c = <P as FsProvider>::FlushFut<'c>

§

type ReadDirFut<'c> where Self: 'c = <P as FsProvider>::ReadDirFut<'c>

§

type LinkFut<'c> where Self: 'c = <P as FsProvider>::LinkFut<'c>

§

type UnlinkFut<'c> where Self: 'c = <P as FsProvider>::UnlinkFut<'c>

§

type ReadMetaFut<'c> where Self: 'c = <P as FsProvider>::ReadMetaFut<'c>

§

type WriteMetaFut<'c> where Self: 'c = <P as FsProvider>::WriteMetaFut<'c>

§

type AllocateFut<'c> where Self: 'c = <P as FsProvider>::AllocateFut<'c>

§

type CloseFut<'c> where Self: 'c = <P as FsProvider>::CloseFut<'c>

§

type ForgetFut<'c> where Self: 'c = <P as FsProvider>::ForgetFut<'c>

§

type LockFut<'c> where Self: 'c = <P as FsProvider>::LockFut<'c>

§

type UnlockFut<'c> where Self: 'c = <P as FsProvider>::UnlockFut<'c>

§

type AddReacapFut<'c> where Self: 'c = <P as FsProvider>::AddReacapFut<'c>

§

type GrantAccessFut<'c> where Self: 'c = <P as FsProvider>::GrantAccessFut<'c>