Skip to main content
aboutsummaryrefslogtreecommitdiffstats
blob: 6ce5a216a339f28e3e9fb54eb95be21cc451bfab (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
/****************************************************************************
 * Copyright (c) 2004 Composent, Inc. and others.
 *
 * This program and the accompanying materials are made
 * available under the terms of the Eclipse Public License 2.0
 * which is available at https://www.eclipse.org/legal/epl-2.0/
 *
 * Contributors:
 *    Composent, Inc. - initial API and implementation
 *
 * SPDX-License-Identifier: EPL-2.0
 *****************************************************************************/
package org.eclipse.ecf.presence.chatroom;

import org.eclipse.core.runtime.IAdaptable;
import org.eclipse.ecf.core.ContainerCreateException;
import org.eclipse.ecf.core.identity.ID;

/**
 * Chat room information. Instances implementing this interface are returned by
 * {@link IChatRoomManager#getChatRoomInfo(String)} or
 * {@link IChatRoomManager#getChatRoomInfos()}
 * 
 * @see IChatRoomManager#getChatRoomInfo(String)
 */
public interface IChatRoomInfo extends IAdaptable {
	/**
	 * Get a description for this room
	 * 
	 * @return String description for this chat room. May be <code>null</code>.
	 */
	public String getDescription();

	/**
	 * Get subject/topic for room
	 * 
	 * @return String topic. May be <code>null</code>.
	 */
	public String getSubject();

	/**
	 * Get the ID associated with this room
	 * 
	 * @return ID for room. Will not be <code>null</code>.
	 */
	public ID getRoomID();

	/**
	 * Get a count of the current number of room participants
	 * 
	 * @return int number of participants
	 */
	public int getParticipantsCount();

	/**
	 * Get a long name for room
	 * 
	 * @return String name. May be <code>null</code>.
	 */
	public String getName();

	/**
	 * 
	 * @return true if room is persistent, false otherwise
	 */
	public boolean isPersistent();

	/**
	 * 
	 * @return true if room connect requires password, false otherwise
	 */
	public boolean requiresPassword();

	/**
	 * 
	 * @return true if room is moderated, false otherwise
	 */
	public boolean isModerated();

	/**
	 * 
	 * @return ID of connected user
	 */
	public ID getConnectedID();

	/**
	 * Create a new IChatRoomContainer instance. This method can be used to
	 * create and connect a container to the chat room identified by this chat
	 * room info object.
	 * 
	 * @return non-null IChatRoomContainer instance. Will not return
	 *         <code>null</code>.
	 * @throws ContainerCreateException
	 *             if chat room container cannot be made
	 */
	public IChatRoomContainer createChatRoomContainer()
			throws ContainerCreateException;

}

Back to the top