public class MUCInitialPresence
extends java.lang.Object
implements org.jivesoftware.smack.packet.ExtensionElement
The amount of discussion history provided on entering a room (perhaps because the user is on a low-bandwidth connection or is using a small-footprint client) could be managed by setting a configured History instance to the MUCInitialPresence instance.
setHistory(MUCInitialPresence.History)
Modifier and Type | Class and Description |
---|---|
static class |
MUCInitialPresence.History
The History class controls the number of characters or messages to receive
when entering a room.
|
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
ELEMENT |
static java.lang.String |
NAMESPACE |
Constructor and Description |
---|
MUCInitialPresence()
Deprecated.
use
MUCInitialPresence(String, int, int, int, Date) instead. |
MUCInitialPresence(java.lang.String password,
int maxChars,
int maxStanzas,
int seconds,
java.util.Date since)
Construct a new MUC initial presence extension.
|
Modifier and Type | Method and Description |
---|---|
static MUCInitialPresence |
from(org.jivesoftware.smack.packet.Stanza packet)
Retrieve the MUCInitialPresence PacketExtension from packet, if any.
|
java.lang.String |
getElementName() |
static MUCInitialPresence |
getFrom(org.jivesoftware.smack.packet.Stanza packet)
Deprecated.
use
from(Stanza) instead |
MUCInitialPresence.History |
getHistory()
Returns the history that manages the amount of discussion history provided on
entering a room.
|
java.lang.String |
getNamespace() |
java.lang.String |
getPassword()
Returns the password to use when the room requires a password.
|
void |
setHistory(MUCInitialPresence.History history)
Deprecated.
use
MUCInitialPresence(String, int, int, int, Date) instead. |
void |
setPassword(java.lang.String password)
Deprecated.
use
MUCInitialPresence(String, int, int, int, Date) instead. |
org.jivesoftware.smack.util.XmlStringBuilder |
toXML(org.jivesoftware.smack.packet.XmlEnvironment enclosingNamespace) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
public static final java.lang.String ELEMENT
public static final java.lang.String NAMESPACE
@Deprecated public MUCInitialPresence()
MUCInitialPresence(String, int, int, int, Date)
instead.public MUCInitialPresence(java.lang.String password, int maxChars, int maxStanzas, int seconds, java.util.Date since)
password
- the optional password used to enter the room.maxChars
- the maximal count of characters of history to request.maxStanzas
- the maximal count of stanzas of history to request.seconds
- the last seconds since when to request history.since
- the date since when to request history.public java.lang.String getElementName()
getElementName
in interface org.jivesoftware.smack.packet.NamedElement
public java.lang.String getNamespace()
getNamespace
in interface org.jivesoftware.smack.packet.FullyQualifiedElement
public org.jivesoftware.smack.util.XmlStringBuilder toXML(org.jivesoftware.smack.packet.XmlEnvironment enclosingNamespace)
toXML
in interface org.jivesoftware.smack.packet.Element
public MUCInitialPresence.History getHistory()
public java.lang.String getPassword()
@Deprecated public void setHistory(MUCInitialPresence.History history)
MUCInitialPresence(String, int, int, int, Date)
instead.history
- that manages the amount of discussion history provided on
entering a room.@Deprecated public void setPassword(java.lang.String password)
MUCInitialPresence(String, int, int, int, Date)
instead.password
- the password to use when the room requires a password.@Deprecated public static MUCInitialPresence getFrom(org.jivesoftware.smack.packet.Stanza packet)
from(Stanza)
insteadpacket
- TODO javadoc me pleasenull
public static MUCInitialPresence from(org.jivesoftware.smack.packet.Stanza packet)
packet
- TODO javadoc me pleasenull