From 903f90e1c17bb450384fa135c4cb9e5c2c803fa3 Mon Sep 17 00:00:00 2001 From: Jesus Fuentes Date: Fri, 9 Mar 2018 07:15:46 -0600 Subject: [PATCH] Update/fix javadocs --- .../main/java/org/jivesoftware/smack/XMPPConnection.java | 8 +++++--- .../main/java/org/jivesoftware/smack/roster/Roster.java | 2 +- .../org/jivesoftware/smack/tcp/XMPPTCPConnection.java | 2 +- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/smack-core/src/main/java/org/jivesoftware/smack/XMPPConnection.java b/smack-core/src/main/java/org/jivesoftware/smack/XMPPConnection.java index aee75aafc..873cbdbd5 100644 --- a/smack-core/src/main/java/org/jivesoftware/smack/XMPPConnection.java +++ b/smack-core/src/main/java/org/jivesoftware/smack/XMPPConnection.java @@ -43,13 +43,15 @@ import org.jxmpp.jid.EntityFullJid; * // Most servers require you to login before performing other tasks. * con.login("jsmith", "mypass"); * // Start a new conversation with John Doe and send him a message. - * Chat chat = ChatManager.getInstanceFor(con).createChat("jdoe@igniterealtime.org", new MessageListener() { - * public void processMessage(Chat chat, Message message) { + * ChatManager chatManager = ChatManager.getInstanceFor(con); + * chatManager.addIncomingListener(new IncomingChatMessageListener() { + * public void newIncomingMessage(EntityBareJid from, Message message, Chat chat) { * // Print out any messages we get back to standard out. * System.out.println("Received message: " + message); * } * }); - * chat.sendMessage("Howdy!"); + * Chat chat = chatManager.chatWith("jdoe@igniterealtime.org"); + * chat.send("Howdy!"); * // Disconnect from the server * con.disconnect(); * diff --git a/smack-im/src/main/java/org/jivesoftware/smack/roster/Roster.java b/smack-im/src/main/java/org/jivesoftware/smack/roster/Roster.java index b5c6b2fef..501d65023 100644 --- a/smack-im/src/main/java/org/jivesoftware/smack/roster/Roster.java +++ b/smack-im/src/main/java/org/jivesoftware/smack/roster/Roster.java @@ -78,7 +78,7 @@ import org.jxmpp.util.cache.LruCache; * Represents a user's roster, which is the collection of users a person receives * presence updates for. Roster items are categorized into groups for easier management. * - * Others users may attempt to subscribe to this user using a subscription request. Three + * Other users may attempt to subscribe to this user using a subscription request. Three * modes are supported for handling these requests: