jetstream_9p::ninep_2000_l
Trait NineP200L
pub trait NineP200L: Send + Sync {
// Required methods
fn version(
&mut self,
tag: u16,
version: &Tversion,
) -> impl Future<Output = Result<Rversion>> + Send + Sync;
fn auth(
&mut self,
tag: u16,
auth: &Tauth,
) -> impl Future<Output = Result<Rauth>> + Send + Sync;
fn flush(
&mut self,
tag: u16,
flush: &Tflush,
) -> impl Future<Output = Result<()>> + Send + Sync;
fn walk(
&mut self,
tag: u16,
walk: &Twalk,
) -> impl Future<Output = Result<Rwalk>> + Send + Sync;
fn read(
&mut self,
tag: u16,
read: &Tread,
) -> impl Future<Output = Result<Rread>> + Send + Sync;
fn write(
&mut self,
tag: u16,
write: &Twrite,
) -> impl Future<Output = Result<Rwrite>> + Send + Sync;
fn clunk(
&mut self,
tag: u16,
clunk: &Tclunk,
) -> impl Future<Output = Result<()>> + Send + Sync;
fn remove(
&mut self,
tag: u16,
remove: &Tremove,
) -> impl Future<Output = Result<()>> + Send + Sync;
fn attach(
&mut self,
tag: u16,
attach: &Tattach,
) -> impl Future<Output = Result<Rattach>> + Send + Sync;
fn statfs(
&mut self,
tag: u16,
statfs: &Tstatfs,
) -> impl Future<Output = Result<Rstatfs>> + Send + Sync;
fn lopen(
&mut self,
tag: u16,
lopen: &Tlopen,
) -> impl Future<Output = Result<Rlopen>> + Send + Sync;
fn lcreate(
&mut self,
tag: u16,
lcreate: &Tlcreate,
) -> impl Future<Output = Result<Rlcreate>> + Send + Sync;
fn symlink(
&mut self,
tag: u16,
symlink: &Tsymlink,
) -> impl Future<Output = Result<Rsymlink>> + Send + Sync;
fn mknod(
&mut self,
tag: u16,
mknod: &Tmknod,
) -> impl Future<Output = Result<Rmknod>> + Send + Sync;
fn rename(
&mut self,
tag: u16,
rename: &Trename,
) -> impl Future<Output = Result<()>> + Send + Sync;
fn readlink(
&mut self,
tag: u16,
readlink: &Treadlink,
) -> impl Future<Output = Result<Rreadlink>> + Send + Sync;
fn get_attr(
&mut self,
tag: u16,
get_attr: &Tgetattr,
) -> impl Future<Output = Result<Rgetattr>> + Send + Sync;
fn set_attr(
&mut self,
tag: u16,
set_attr: &Tsetattr,
) -> impl Future<Output = Result<()>> + Send + Sync;
fn xattr_walk(
&mut self,
tag: u16,
xattr_walk: &Txattrwalk,
) -> impl Future<Output = Result<Rxattrwalk>> + Send + Sync;
fn xattr_create(
&mut self,
tag: u16,
xattr_create: &Txattrcreate,
) -> impl Future<Output = Result<()>> + Send + Sync;
fn readdir(
&mut self,
tag: u16,
readdir: &Treaddir,
) -> impl Future<Output = Result<Rreaddir>> + Send + Sync;
fn fsync(
&mut self,
tag: u16,
fsync: &Tfsync,
) -> impl Future<Output = Result<()>> + Send + Sync;
fn lock(
&mut self,
tag: u16,
lock: &Tlock,
) -> impl Future<Output = Result<Rlock>> + Send + Sync;
fn get_lock(
&mut self,
tag: u16,
get_lock: &Tgetlock,
) -> impl Future<Output = Result<Rgetlock>> + Send + Sync;
fn link(
&mut self,
tag: u16,
link: &Tlink,
) -> impl Future<Output = Result<()>> + Send + Sync;
fn mkdir(
&mut self,
tag: u16,
mkdir: &Tmkdir,
) -> impl Future<Output = Result<Rmkdir>> + Send + Sync;
fn rename_at(
&mut self,
tag: u16,
rename_at: &Trenameat,
) -> impl Future<Output = Result<()>> + Send + Sync;
fn unlink_at(
&mut self,
tag: u16,
unlink_at: &Tunlinkat,
) -> impl Future<Output = Result<()>> + Send + Sync;
}
9p
Required Methods
fn version( &mut self, tag: u16, version: &Tversion, ) -> impl Future<Output = Result> + Send + Sync
The version message is the first message sent on a connection. It is used to negotiate the 9P protocol version and maximum message size.
fn auth( &mut self, tag: u16, auth: &Tauth, ) -> impl Future<Output = Result> + Send + Sync
The auth message is used to authenticate a user to the server. It is sent after the version message and before any other messages. The auth message is optional and may be ignored by the server.
fn flush( &mut self, tag: u16, flush: &Tflush, ) -> impl Future<Output = Result<()>> + Send + Sync
The flush message is used to flush pending I/O requests.
fn walk( &mut self, tag: u16, walk: &Twalk, ) -> impl Future<Output = Result> + Send + Sync
The walk message is used to traverse the file system hierarchy. It is sent by the client and responded to by the server.
fn read( &mut self, tag: u16, read: &Tread, ) -> impl Future<Output = Result> + Send + Sync
The read message is used to read data from a file.
fn write( &mut self, tag: u16, write: &Twrite, ) -> impl Future<Output = Result> + Send + Sync
The write message is used to write data to a file.
fn clunk( &mut self, tag: u16, clunk: &Tclunk, ) -> impl Future<Output = Result<()>> + Send + Sync
The clunk message is used to release a fid.
fn remove( &mut self, tag: u16, remove: &Tremove, ) -> impl Future<Output = Result<()>> + Send + Sync
The remove message is used to remove a file.
fn attach( &mut self, tag: u16, attach: &Tattach, ) -> impl Future<Output = Result> + Send + Sync
The attach message is used to associate a fid with a file.
fn statfs( &mut self, tag: u16, statfs: &Tstatfs, ) -> impl Future<Output = Result> + Send + Sync
The statfs message is used to retrieve file system information.
fn lopen( &mut self, tag: u16, lopen: &Tlopen, ) -> impl Future<Output = Result> + Send + Sync
The lopen message is used to open a file.
fn lcreate( &mut self, tag: u16, lcreate: &Tlcreate, ) -> impl Future<Output = Result> + Send + Sync
The lcreate message is used to create a file.
fn symlink( &mut self, tag: u16, symlink: &Tsymlink, ) -> impl Future<Output = Result> + Send + Sync
The symlink message is used to create a symbolic link.
fn mknod( &mut self, tag: u16, mknod: &Tmknod, ) -> impl Future<Output = Result> + Send + Sync
The mknod message is used to create a device file.
fn rename( &mut self, tag: u16, rename: &Trename, ) -> impl Future<Output = Result<()>> + Send + Sync
The rename message is used to rename a file.
fn readlink( &mut self, tag: u16, readlink: &Treadlink, ) -> impl Future<Output = Result> + Send + Sync
The readlink message is used to read the target of a symbolic link.
fn get_attr( &mut self, tag: u16, get_attr: &Tgetattr, ) -> impl Future<Output = Result> + Send + Sync
The getattr message is used to retrieve file attributes.
fn set_attr( &mut self, tag: u16, set_attr: &Tsetattr, ) -> impl Future<Output = Result<()>> + Send + Sync
The setattr message is used to set file attributes.
fn xattr_walk( &mut self, tag: u16, xattr_walk: &Txattrwalk, ) -> impl Future<Output = Result> + Send + Sync
The xattrwalk message is used to traverse extended attributes.
fn xattr_create( &mut self, tag: u16, xattr_create: &Txattrcreate, ) -> impl Future<Output = Result<()>> + Send + Sync
The xattrcreate message is used to create an extended attribute.
fn readdir( &mut self, tag: u16, readdir: &Treaddir, ) -> impl Future<Output = Result> + Send + Sync
The readdir message is used to read a directory.
fn fsync( &mut self, tag: u16, fsync: &Tfsync, ) -> impl Future<Output = Result<()>> + Send + Sync
The fsync message is used to synchronize a file’s data and metadata.
fn lock( &mut self, tag: u16, lock: &Tlock, ) -> impl Future<Output = Result> + Send + Sync
The lock message is used to lock a file.
fn get_lock( &mut self, tag: u16, get_lock: &Tgetlock, ) -> impl Future<Output = Result> + Send + Sync
The getlock message is used to retrieve a file’s locks.
fn link( &mut self, tag: u16, link: &Tlink, ) -> impl Future<Output = Result<()>> + Send + Sync
The link message is used to create a hard link.
fn mkdir( &mut self, tag: u16, mkdir: &Tmkdir, ) -> impl Future<Output = Result> + Send + Sync
The mkdir message is used to create a directory.
fn rename_at( &mut self, tag: u16, rename_at: &Trenameat, ) -> impl Future<Output = Result<()>> + Send + Sync
The renameat message is used to rename a file.
fn unlink_at( &mut self, tag: u16, unlink_at: &Tunlinkat, ) -> impl Future<Output = Result<()>> + Send + Sync
The unlinkat message is used to remove a file.
Dyn Compatibility
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.