Struct mas_matrix::ProvisionRequest
source · pub struct ProvisionRequest { /* private fields */ }
Implementations§
source§impl ProvisionRequest
impl ProvisionRequest
sourcepub fn new(mxid: impl Into<String>, sub: impl Into<String>) -> Self
pub fn new(mxid: impl Into<String>, sub: impl Into<String>) -> Self
Create a new ProvisionRequest
.
§Parameters
mxid
- The Matrix ID to provision.sub
- Thesub
of the user, aka the internal ID.
sourcepub fn set_displayname(self, displayname: String) -> Self
pub fn set_displayname(self, displayname: String) -> Self
sourcepub fn unset_displayname(self) -> Self
pub fn unset_displayname(self) -> Self
Ask to unset the displayname of the user.
sourcepub fn on_displayname<F>(&self, callback: F) -> &Self
pub fn on_displayname<F>(&self, callback: F) -> &Self
Call the given callback if the displayname should be set or unset.
§Parameters
callback
- The callback to call.
sourcepub fn set_avatar_url(self, avatar_url: String) -> Self
pub fn set_avatar_url(self, avatar_url: String) -> Self
sourcepub fn unset_avatar_url(self) -> Self
pub fn unset_avatar_url(self) -> Self
Ask to unset the avatar URL of the user.
sourcepub fn on_avatar_url<F>(&self, callback: F) -> &Self
pub fn on_avatar_url<F>(&self, callback: F) -> &Self
Call the given callback if the avatar URL should be set or unset.
§Parameters
callback
- The callback to call.
sourcepub fn set_emails(self, emails: Vec<String>) -> Self
pub fn set_emails(self, emails: Vec<String>) -> Self
sourcepub fn unset_emails(self) -> Self
pub fn unset_emails(self) -> Self
Ask to unset the emails of the user.
Auto Trait Implementations§
impl Freeze for ProvisionRequest
impl RefUnwindSafe for ProvisionRequest
impl Send for ProvisionRequest
impl Sync for ProvisionRequest
impl Unpin for ProvisionRequest
impl UnwindSafe for ProvisionRequest
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