pub struct BaseApi { /* private fields */ }
Expand description
The default implemented API for interfacing with the IPFS RPC API.
This functionality is achieved by implementing the PeerApi
trait for BaseApi
.
To change or enhance any of the functionality of interfacing with the IPFS RPC API,
users of ipfs-webdav
need to implement the PeerApi
trait for their implementation
of an API that interfaces with the IPFS PRC API.
Implementations§
Trait Implementations§
Source§impl PeerApi for BaseApi
impl PeerApi for BaseApi
Source§fn cp<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
path: &'life1 str,
dest: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn cp<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
path: &'life1 str,
dest: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Add references to IPFS files and directories in MFS (or copy within MFS).
Source§fn flush<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn flush<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Flush a given path’s data to disk.
Source§fn ls<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<PeerEntry>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn ls<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<PeerEntry>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
List directories in the local mutable namespace.
Source§fn mkdir<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<PeerEntry, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn mkdir<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<PeerEntry, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Make directories.
Source§fn mv<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
path: &'life1 str,
dest: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn mv<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
path: &'life1 str,
dest: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Move files.
Source§fn read<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 str,
offset: usize,
count: usize,
) -> Pin<Box<dyn Future<Output = Result<Bytes, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn read<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 str,
offset: usize,
count: usize,
) -> Pin<Box<dyn Future<Output = Result<Bytes, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Read a file in a given MFS.
Source§fn rm<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn rm<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Remove a file.
Source§fn stat<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<PeerEntry, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn stat<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<PeerEntry, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Display file status.
Source§fn write<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 str,
offset: usize,
truncate: bool,
data: Bytes,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn write<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 str,
offset: usize,
truncate: bool,
data: Bytes,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Write to a mutable file in a given filesystem.
Auto Trait Implementations§
impl !Freeze for BaseApi
impl !RefUnwindSafe for BaseApi
impl Send for BaseApi
impl Sync for BaseApi
impl Unpin for BaseApi
impl !UnwindSafe for BaseApi
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