1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19 package net.sf.dexterim.core;
20
21 import net.sf.dexterim.core.event.ConversationListener;
22
23 /*** Represents a Conversation with one or more Contacts
24 * @author Christoph Walcher
25 */
26 public interface Conversation {
27 /*** Add <B>contact</B> to the conversation.
28 * @param contact The Contact object that should join the Conversation
29 */
30 void join(Contact contact);
31
32 /*** Connects the Conversation object to the messenger network
33 */
34 void open();
35
36 /*** Sends a Message in encoded in a String over the implements network. It's
37 * in the responsibility of the implementing Class to encode the String
38 * message
39 */
40 void sendMessage(String message);
41
42 /*** Ends the Conversation and frees unused Resources
43 *
44 */
45 void close();
46
47 /***
48 * @param listener
49 */
50 void addConversationListener(ConversationListener listener);
51
52 /***
53 * @param listener
54 */
55 void removeConversationListener(ConversationListener listener);
56 }