Function xmpp::muc::private_message::send_room_private_message
source · pub async fn send_room_private_message<C: ServerConnector>(
agent: &mut Agent<C>,
room: BareJid,
recipient: RoomNick,
lang: &str,
text: &str,
) -> Result<String, Error>
Expand description
Send a private message to a given MUC room member.
Returns the generated message ID.
§Arguments
agent
: The agent to use to send the message.room
: The JID of the room.recipient
: The nickname of the recipient within the room.type_
: The type of message to send. For a message to a MUC room, this should beMessageType::Groupchat
. For a private message to a MUC room member or regular contact, this should beMessageType::Chat
.lang
: The language of the message. (See IETF RFC 5646)text
: The text of the message.
Returns the generated message ID, or an error if the message could not be sent.