pub struct AppKeys { /* private fields */ }Implementations§
Source§impl AppKeys
impl AppKeys
pub fn new(devices: Vec<DeviceEntry>) -> AppKeys
pub fn add_device(&mut self, device: DeviceEntry)
pub fn remove_device(&mut self, identity_pubkey: &PublicKey)
pub fn get_device(&self, identity_pubkey: &PublicKey) -> Option<&DeviceEntry>
pub fn get_all_devices(&self) -> Vec<DeviceEntry>
pub fn set_device_labels( &mut self, identity_pubkey: PublicKey, device_label: Option<String>, client_label: Option<String>, updated_at: Option<u64>, )
pub fn get_device_labels( &self, identity_pubkey: &PublicKey, ) -> Option<&DeviceLabels>
pub fn get_all_device_labels(&self) -> Vec<(PublicKey, DeviceLabels)>
pub fn get_event(&self, owner_pubkey: PublicKey) -> UnsignedEvent
pub fn get_event_at( &self, owner_pubkey: PublicKey, created_at_secs: u64, ) -> UnsignedEvent
pub fn get_encrypted_event( &self, owner_keys: &Keys, ) -> Result<UnsignedEvent, Error>
pub fn get_encrypted_event_at( &self, owner_keys: &Keys, created_at_secs: u64, ) -> Result<UnsignedEvent, Error>
pub fn from_event(event: &Event) -> Result<AppKeys, Error>
pub fn from_event_with_labels( event: &Event, owner_keys: &Keys, ) -> Result<AppKeys, Error>
pub fn serialize(&self) -> Result<String, Error>
pub fn deserialize(json: &str) -> Result<AppKeys, Error>
pub fn merge(&self, other: &AppKeys) -> AppKeys
Trait Implementations§
Source§impl OwnerClaimVerifier for AppKeys
impl OwnerClaimVerifier for AppKeys
fn has_device( &self, _device_pubkey: DevicePubkey, device_identity: PublicKey, ) -> bool
Auto Trait Implementations§
impl Freeze for AppKeys
impl RefUnwindSafe for AppKeys
impl Send for AppKeys
impl Sync for AppKeys
impl Unpin for AppKeys
impl UnsafeUnpin for AppKeys
impl UnwindSafe for AppKeys
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