ProfilesMsg

Struct ProfilesMsg 

Source
pub struct ProfilesMsg {}
Expand description

ProfilesMsg is the builder to generate Desmos x/profiles messages.

Implementations§

Source§

impl ProfilesMsg

Source

pub fn save_profile( dtag: Option<&str>, nickname: Option<&str>, bio: Option<&str>, profile_picture: Option<&str>, cover_picture: Option<&str>, creator: Addr, ) -> MsgSaveProfile

Creates an instance of MsgSaveProfile.

  • dtag - Unique profile tag, set None if editing the profile without modifying this field.
  • nickname - Human readable name of the profile. It will not change the current profile nickname if set this field to None.
  • bio - Biography of the profile. It will not change the current profile bio if set this field to None.
  • profile_picture - URL to the profile picture. It will not change the current profile profile picture if set this field to None.
  • cover_picture - URL to the cover cover picture. It will not change the current profile cover picture if set this field to None.
  • creator - Address of which is creating the profile.
Source

pub fn delete_profile(creator: Addr) -> MsgDeleteProfile

Creates an instance of MsgDeleteProfile.

  • creator - Address of the profile to delete.
Source

pub fn request_dtag_transfer( sender: Addr, receiver: Addr, ) -> MsgRequestDTagTransfer

Creates an instance of MsgRequestDTagTransfer.

  • sender - Address of who is going to send the DTag.
  • receiver - Address of who is going to receive the DTag
Source

pub fn accept_dtag_transfer_request( new_dtag: &str, sender: Addr, receiver: Addr, ) -> MsgAcceptDTagTransferRequest

Creates an instance of MsgAcceptDTagTransferRequest.

  • new_dtag - The DTag to accept.
  • sender - Address of who has sent the DTag.
  • receiver - Address of who is receiving the DTag.
Source

pub fn refuse_dtag_transfer_request( sender: Addr, receiver: Addr, ) -> MsgRefuseDTagTransferRequest

Creates an instance of MsgRefuseDTagTransferRequest.

  • sender - Address of who has started the DTag transfer.
  • receiver - Address of who was supposed to receive the DTag.
Source

pub fn cancel_dtag_transfer_request( receiver: Addr, sender: Addr, ) -> MsgCancelDTagTransferRequest

Creates an instance of MsgCancelDTagTransferRequest.

  • receiver - Address of who was supposed to receive the DTag.
  • sender - Address of who has started the DTag transfer.

Creates an instance of MsgLinkChainAccount.

  • chain_address - Data of the external chain address to be connected with the Desmos profile.
  • proof - The ownership proof of the external chain address.
  • chain_config - The configuration of the external chain.
  • signer - Address associated with the profile to which link the external account.

Creates an instance of MsgUnlinkChainAccount.

  • owner - The profile address from which to remove the link.
  • chain_name - The chain name associated with the link to be removed.
  • target - The external address to be removed.
Source

pub fn set_default_external_address( chain_name: &str, target: &str, signer: Addr, ) -> MsgSetDefaultExternalAddress

Creates an instance of MsgSetDefaultExternalAddress.

  • chain_name - The chain name associated with the link to be set as default one.
  • target - The external address to be set as default one.
  • signer - The profile address which to set a default external address.

Creates an instance of MsgLinkApplication.

  • sender - Sender of the connection request.
  • link_data - The data related to the application to which connect.
  • call_data - Hex encoded call data that will be sent to the data source in order to verify the link.
  • source_port - The port on which the packet will be sent.
  • source_channel - The channel by which the packet will be sent.
  • timeout_height - Timeout height relative to the current block height. The timeout is disabled when set to 0.
  • timeout_timestamp - Timeout timestamp (in nanoseconds) relative to the current block timestamp. The timeout is disabled when set to 0.

Creates an instance of MsgUnlinkApplication.

  • application - The name of the application to unlink.
  • username - The username inside the application to unlink.
  • signer - The Desmos account from which the application should be unlinked.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<U> As for U

Source§

fn as_<T>(self) -> T
where T: CastFrom<U>,

Casts self to type T. The semantics of numeric casting with the as operator are followed, so <T as As>::as_::<U> can be used in the same way as T as U for numeric conversions. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.