mirror of
https://codeberg.org/Mercury-IM/Smack
synced 2024-11-26 16:22:06 +01:00
Add Message(String,String)
This commit is contained in:
parent
15d60ea876
commit
ba2df2a995
1 changed files with 11 additions and 0 deletions
|
@ -87,6 +87,17 @@ public final class Message extends Packet {
|
||||||
setType(type);
|
setType(type);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Creates a new message to the specified recipient and with the specified body.
|
||||||
|
*
|
||||||
|
* @param to the user to send the message to.
|
||||||
|
* @param body the body of the message.
|
||||||
|
*/
|
||||||
|
public Message(String to, String body) {
|
||||||
|
this(to);
|
||||||
|
setBody(body);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the type of the message. If no type has been set this method will return {@link
|
* Returns the type of the message. If no type has been set this method will return {@link
|
||||||
* org.jivesoftware.smack.packet.Message.Type#normal}.
|
* org.jivesoftware.smack.packet.Message.Type#normal}.
|
||||||
|
|
Loading…
Reference in a new issue