1
0
Fork 0
mirror of https://codeberg.org/Mercury-IM/Smack synced 2025-09-10 18:59:41 +02:00

Merge branch '4.1'

Conflicts:
	version.gradle
This commit is contained in:
Florian Schmaus 2015-03-11 20:51:08 +01:00
commit 369878b6d9
8 changed files with 48 additions and 12 deletions

View file

@ -201,7 +201,7 @@ public class EntityCapsManager extends Manager {
DiscoverInfo info = CAPS_CACHE.get(nodeVer);
// If it was not in CAPS_CACHE, try to retrieve the information from persistentCache
if (info == null) {
if (info == null && persistentCache != null) {
info = persistentCache.lookup(nodeVer);
// Promote the information to CAPS_CACHE if one was found
if (info != null) {

View file

@ -18,6 +18,7 @@ package org.jivesoftware.smackx.disco.packet;
import org.jivesoftware.smack.packet.IQ;
import org.jivesoftware.smack.util.StringUtils;
import org.jivesoftware.smack.util.TypedCloneable;
import org.jivesoftware.smack.util.XmlStringBuilder;
import org.jxmpp.util.XmppStringUtils;
@ -38,7 +39,7 @@ import java.util.Set;
*
* @author Gaston Dombiak
*/
public class DiscoverInfo extends IQ implements Cloneable {
public class DiscoverInfo extends IQ implements TypedCloneable<DiscoverInfo> {
public static final String ELEMENT = QUERY_ELEMENT;
public static final String NAMESPACE = "http://jabber.org/protocol/disco#info";
@ -266,7 +267,7 @@ public class DiscoverInfo extends IQ implements Cloneable {
* attributes.
*
*/
public static class Identity implements Comparable<Identity>, Cloneable {
public static class Identity implements Comparable<Identity>, TypedCloneable<Identity> {
private final String category;
private final String type;
@ -473,7 +474,7 @@ public class DiscoverInfo extends IQ implements Cloneable {
* as well as specific feature types of interest, if any (e.g., for the purpose of feature
* negotiation).
*/
public static class Feature implements Cloneable {
public static class Feature implements TypedCloneable<Feature> {
private final String variable;

View file

@ -150,9 +150,7 @@ public class MUCItem implements NamedElement {
xml.optAttribute("affiliation", getAffiliation());
xml.optAttribute("jid", getJid());
xml.optAttribute("nick", getNick());
if (role != null && role != MUCRole.none) {
xml.attribute("role", getRole());
}
xml.optAttribute("role", getRole());
xml.rightAngleBracket();
xml.optElement("reason", getReason());
if (getActor() != null) {

View file

@ -16,5 +16,6 @@
<className>org.jivesoftware.smackx.xdatalayout.XDataLayoutManager</className>
<className>org.jivesoftware.smackx.xdatavalidation.XDataValidationManager</className>
<className>org.jivesoftware.smackx.receipts.DeliveryReceiptManager</className>
<className>org.jivesoftware.smackx.iqversion.VersionManager</className>
</startupClasses>
</smack>