pub struct DeadDrop { /* private fields */ }Implementations§
Source§impl DeadDrop
impl DeadDrop
pub fn builder() -> DeadDropBuilder
Sourcepub fn connect() -> Result<Self>
pub fn connect() -> Result<Self>
Open the default data directory (DEADDROP_HOME or platform project dir).
This is synchronous: it loads identity and SQLite. It does not dial a network.
pub fn open_dir(dir: &Path) -> Result<Self>
pub async fn send( &self, to: Recipient, payload: impl AsRef<[u8]>, ) -> Result<ObjectId>
pub async fn send_file( &self, path: impl AsRef<Path>, to: Recipient, ) -> Result<ObjectId>
pub fn send_with(&self, opts: SendOpts) -> Result<ObjectId>
pub fn receive(&self) -> Result<Vec<InboxItem>>
pub fn events(&self) -> Vec<Event>
pub fn peer_id(&self) -> PeerId
pub fn node(&self) -> &Node
Auto Trait Implementations§
impl !Freeze for DeadDrop
impl RefUnwindSafe for DeadDrop
impl Send for DeadDrop
impl Sync for DeadDrop
impl Unpin for DeadDrop
impl UnsafeUnpin for DeadDrop
impl UnwindSafe for DeadDrop
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