mirror of
https://github.com/vanitasvitae/Smack.git
synced 2024-11-23 04:22:05 +01:00
Added JID of the room whose information was discovered. SMACK-57
git-svn-id: http://svn.igniterealtime.org/svn/repos/smack/trunk@2493 b35dd754-fafc-0310-a699-88a17e54d16e
This commit is contained in:
parent
7aac6e971a
commit
bdd395b0dc
1 changed files with 14 additions and 0 deletions
|
@ -32,6 +32,10 @@ import org.jivesoftware.smackx.Form;
|
||||||
*/
|
*/
|
||||||
public class RoomInfo {
|
public class RoomInfo {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* JID of the room. The node of the JID is commonly used as the ID of the room or name.
|
||||||
|
*/
|
||||||
|
private String room;
|
||||||
/**
|
/**
|
||||||
* Description of the room.
|
* Description of the room.
|
||||||
*/
|
*/
|
||||||
|
@ -72,6 +76,7 @@ public class RoomInfo {
|
||||||
|
|
||||||
RoomInfo(DiscoverInfo info) {
|
RoomInfo(DiscoverInfo info) {
|
||||||
super();
|
super();
|
||||||
|
this.room = info.getFrom();
|
||||||
// Get the information based on the discovered features
|
// Get the information based on the discovered features
|
||||||
this.membersOnly = info.containsFeature("muc_membersonly");
|
this.membersOnly = info.containsFeature("muc_membersonly");
|
||||||
this.moderated = info.containsFeature("muc_moderated");
|
this.moderated = info.containsFeature("muc_moderated");
|
||||||
|
@ -90,6 +95,15 @@ public class RoomInfo {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns the JID of the room whose information was discovered.
|
||||||
|
*
|
||||||
|
* @return the JID of the room whose information was discovered.
|
||||||
|
*/
|
||||||
|
public String getRoom() {
|
||||||
|
return room;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the discovered description of the room.
|
* Returns the discovered description of the room.
|
||||||
*
|
*
|
||||||
|
|
Loading…
Reference in a new issue