1
0
Fork 0
mirror of https://github.com/vanitasvitae/Smack.git synced 2024-11-22 12:02:05 +01:00

Add FinalClass checkstyle check

And mark affected classes final.
This commit is contained in:
Florian Schmaus 2015-04-06 10:45:12 +02:00
parent 5ae1fbd25a
commit b4694ec152
72 changed files with 80 additions and 79 deletions

View file

@ -54,6 +54,7 @@
</module> </module>
<module name="JavadocPackage"/> <module name="JavadocPackage"/>
<module name="TreeWalker"> <module name="TreeWalker">
<module name="FinalClass"/>
<module name="FileContentsHolder"/> <module name="FileContentsHolder"/>
<module name="UnusedImports"> <module name="UnusedImports">
<property name="processJavadoc" value="true"/> <property name="processJavadoc" value="true"/>

View file

@ -59,7 +59,7 @@ import android.os.SystemClock;
* functionality. * functionality.
* </p> * </p>
*/ */
public class ServerPingWithAlarmManager extends Manager { public final class ServerPingWithAlarmManager extends Manager {
private static final Logger LOGGER = Logger.getLogger(ServerPingWithAlarmManager.class private static final Logger LOGGER = Logger.getLogger(ServerPingWithAlarmManager.class
.getName()); .getName());

View file

@ -22,7 +22,7 @@ import android.util.Base64;
* A Base 64 encoding implementation based on android.util.Base64. * A Base 64 encoding implementation based on android.util.Base64.
* @author Florian Schmaus * @author Florian Schmaus
*/ */
public class AndroidBase64Encoder implements org.jivesoftware.smack.util.stringencoder.Base64.Encoder { public final class AndroidBase64Encoder implements org.jivesoftware.smack.util.stringencoder.Base64.Encoder {
private static AndroidBase64Encoder instance = new AndroidBase64Encoder(); private static AndroidBase64Encoder instance = new AndroidBase64Encoder();

View file

@ -23,7 +23,7 @@ import org.jivesoftware.smack.util.stringencoder.StringEncoder;
import android.util.Base64; import android.util.Base64;
public class AndroidBase64UrlSafeEncoder implements StringEncoder { public final class AndroidBase64UrlSafeEncoder implements StringEncoder {
private static AndroidBase64UrlSafeEncoder instance = new AndroidBase64UrlSafeEncoder(); private static AndroidBase64UrlSafeEncoder instance = new AndroidBase64UrlSafeEncoder();

View file

@ -30,7 +30,7 @@ import org.jivesoftware.smack.proxy.ProxyInfo;
* @see XMPPBOSHConnection * @see XMPPBOSHConnection
* @author Guenther Niess * @author Guenther Niess
*/ */
public class BOSHConfiguration extends ConnectionConfiguration { public final class BOSHConfiguration extends ConnectionConfiguration {
private final boolean https; private final boolean https;
private final String file; private final String file;
@ -73,7 +73,7 @@ public class BOSHConfiguration extends ConnectionConfiguration {
return new Builder(); return new Builder();
} }
public static class Builder extends ConnectionConfiguration.Builder<Builder, BOSHConfiguration> { public static final class Builder extends ConnectionConfiguration.Builder<Builder, BOSHConfiguration> {
private boolean https; private boolean https;
private String file; private String file;

View file

@ -271,7 +271,7 @@ public class PacketCollector {
return new Configuration(); return new Configuration();
} }
public static class Configuration { public static final class Configuration {
private StanzaFilter packetFilter; private StanzaFilter packetFilter;
private int size = SmackConfiguration.getPacketCollectorSize(); private int size = SmackConfiguration.getPacketCollectorSize();
private PacketCollector collectorToReset; private PacketCollector collectorToReset;

View file

@ -47,7 +47,7 @@ import java.util.logging.Logger;
* @author Francisco Vives * @author Francisco Vives
* @author Luca Stucchi * @author Luca Stucchi
*/ */
public class ReconnectionManager { public final class ReconnectionManager {
private static final Logger LOGGER = Logger.getLogger(ReconnectionManager.class.getName()); private static final Logger LOGGER = Logger.getLogger(ReconnectionManager.class.getName());
private static final Map<AbstractXMPPConnection, ReconnectionManager> INSTANCES = new WeakHashMap<AbstractXMPPConnection, ReconnectionManager>(); private static final Map<AbstractXMPPConnection, ReconnectionManager> INSTANCES = new WeakHashMap<AbstractXMPPConnection, ReconnectionManager>();

View file

@ -60,7 +60,7 @@ public class SmackException extends Exception {
* connection instance. You can modify (e.g. increase) the stanza(/packet) reply timeout with * connection instance. You can modify (e.g. increase) the stanza(/packet) reply timeout with
* {@link XMPPConnection#setPacketReplyTimeout(long)}. * {@link XMPPConnection#setPacketReplyTimeout(long)}.
*/ */
public static class NoResponseException extends SmackException { public static final class NoResponseException extends SmackException {
/** /**
* *
*/ */

View file

@ -18,7 +18,7 @@ package org.jivesoftware.smack.compress.packet;
import org.jivesoftware.smack.packet.FullStreamElement; import org.jivesoftware.smack.packet.FullStreamElement;
public class Compressed extends FullStreamElement { public final class Compressed extends FullStreamElement {
public static final String ELEMENT = "compressed"; public static final String ELEMENT = "compressed";
public static final String NAMESPACE = Compress.NAMESPACE; public static final String NAMESPACE = Compress.NAMESPACE;

View file

@ -27,7 +27,7 @@ import org.jivesoftware.smack.util.Objects;
* @author Alexander Wenckus * @author Alexander Wenckus
* *
*/ */
public class IQTypeFilter extends FlexibleStanzaTypeFilter<IQ> { public final class IQTypeFilter extends FlexibleStanzaTypeFilter<IQ> {
public static final StanzaFilter GET = new IQTypeFilter(Type.get); public static final StanzaFilter GET = new IQTypeFilter(Type.get);
public static final StanzaFilter SET = new IQTypeFilter(Type.set); public static final StanzaFilter SET = new IQTypeFilter(Type.set);

View file

@ -27,7 +27,7 @@ import org.jivesoftware.smack.packet.Message.Type;
* @see org.jivesoftware.smack.packet.Message.Type * @see org.jivesoftware.smack.packet.Message.Type
* @author Ward Harold * @author Ward Harold
*/ */
public class MessageTypeFilter extends FlexibleStanzaTypeFilter<Message> { public final class MessageTypeFilter extends FlexibleStanzaTypeFilter<Message> {
public static final StanzaFilter NORMAL = new MessageTypeFilter(Type.normal); public static final StanzaFilter NORMAL = new MessageTypeFilter(Type.normal);
public static final StanzaFilter CHAT = new MessageTypeFilter(Type.chat); public static final StanzaFilter CHAT = new MessageTypeFilter(Type.chat);

View file

@ -22,7 +22,7 @@ import org.jivesoftware.smack.packet.Message;
/** /**
* Filters message stanzas which have at least one body. * Filters message stanzas which have at least one body.
*/ */
public class MessageWithBodiesFilter extends FlexibleStanzaTypeFilter<Message> { public final class MessageWithBodiesFilter extends FlexibleStanzaTypeFilter<Message> {
public static final StanzaFilter INSTANCE = new MessageWithBodiesFilter(); public static final StanzaFilter INSTANCE = new MessageWithBodiesFilter();

View file

@ -22,7 +22,7 @@ import org.jivesoftware.smack.packet.Message;
/** /**
* Filters message stanzas which have at least one body. * Filters message stanzas which have at least one body.
*/ */
public class MessageWithSubjectFilter extends FlexibleStanzaTypeFilter<Message> { public final class MessageWithSubjectFilter extends FlexibleStanzaTypeFilter<Message> {
public static final StanzaFilter INSTANCE = new MessageWithSubjectFilter(); public static final StanzaFilter INSTANCE = new MessageWithSubjectFilter();

View file

@ -24,7 +24,7 @@ import org.jivesoftware.smack.util.Objects;
* A filter for Presence types. Returns true only if the stanza is an Presence stanza(/packet) and it matches the type provided in the * A filter for Presence types. Returns true only if the stanza is an Presence stanza(/packet) and it matches the type provided in the
* constructor. * constructor.
*/ */
public class PresenceTypeFilter extends FlexibleStanzaTypeFilter<Presence> { public final class PresenceTypeFilter extends FlexibleStanzaTypeFilter<Presence> {
public static final PresenceTypeFilter AVAILABLE = new PresenceTypeFilter(Type.available); public static final PresenceTypeFilter AVAILABLE = new PresenceTypeFilter(Type.available);
public static final PresenceTypeFilter UNAVAILABLE = new PresenceTypeFilter(Type.unavailable); public static final PresenceTypeFilter UNAVAILABLE = new PresenceTypeFilter(Type.unavailable);

View file

@ -70,7 +70,7 @@ public class Bind extends IQ {
return xml; return xml;
} }
public static class Feature implements ExtensionElement { public static final class Feature implements ExtensionElement {
public static final Feature INSTANCE = new Feature(); public static final Feature INSTANCE = new Feature();

View file

@ -481,7 +481,7 @@ public final class Message extends Stanza implements TypedCloneable<Message> {
/** /**
* Represents a message subject, its language and the content of the subject. * Represents a message subject, its language and the content of the subject.
*/ */
public static class Subject { public static final class Subject {
private final String subject; private final String subject;
private final String language; private final String language;
@ -544,7 +544,7 @@ public final class Message extends Stanza implements TypedCloneable<Message> {
/** /**
* Represents a message body, its language and the content of the message. * Represents a message body, its language and the content of the message.
*/ */
public static class Body { public static final class Body {
private final String message; private final String message;
private final String language; private final String language;

View file

@ -208,7 +208,7 @@ public class MultiMap<K,V> {
return entrySet; return entrySet;
} }
private static class SimpleMapEntry<K, V> implements Map.Entry<K, V> { private static final class SimpleMapEntry<K, V> implements Map.Entry<K, V> {
private final K key; private final K key;
private V value; private V value;

View file

@ -223,7 +223,7 @@ public class DummyConnection extends AbstractXMPPConnection {
return new Builder(); return new Builder();
} }
public static class Builder public static final class Builder
extends extends
ConnectionConfiguration.Builder<Builder, DummyConnectionConfiguration> { ConnectionConfiguration.Builder<Builder, DummyConnectionConfiguration> {

View file

@ -56,7 +56,7 @@ import org.jivesoftware.smack.provider.ProviderManager;
* *
* @author Gaston Dombiak * @author Gaston Dombiak
*/ */
public class EnhancedDebuggerWindow { public final class EnhancedDebuggerWindow {
private static EnhancedDebuggerWindow instance; private static EnhancedDebuggerWindow instance;

View file

@ -47,7 +47,7 @@ import org.jivesoftware.smackx.disco.ServiceDiscoveryManager;
* *
* @author Georg Lukas * @author Georg Lukas
*/ */
public class CarbonManager extends Manager { public final class CarbonManager extends Manager {
private static Map<XMPPConnection, CarbonManager> INSTANCES = new WeakHashMap<XMPPConnection, CarbonManager>(); private static Map<XMPPConnection, CarbonManager> INSTANCES = new WeakHashMap<XMPPConnection, CarbonManager>();

View file

@ -131,7 +131,7 @@ public class CarbonExtension implements ExtensionElement {
* Stanza(/Packet) extension indicating that a message may not be carbon-copied. Adding this * Stanza(/Packet) extension indicating that a message may not be carbon-copied. Adding this
* extension to any message will disallow that message from being copied. * extension to any message will disallow that message from being copied.
*/ */
public static class Private implements ExtensionElement { public static final class Private implements ExtensionElement {
public static final Private INSTANCE = new Private(); public static final Private INSTANCE = new Private();
public static final String ELEMENT = "private"; public static final String ELEMENT = "private";

View file

@ -27,7 +27,7 @@ import org.jivesoftware.smack.packet.ExtensionElement;
public class ClientStateIndication { public class ClientStateIndication {
public static final String NAMESPACE = "urn:xmpp:csi:0"; public static final String NAMESPACE = "urn:xmpp:csi:0";
public static class Active extends FullStreamElement { public static final class Active extends FullStreamElement {
public static final Active INSTANCE = new Active(); public static final Active INSTANCE = new Active();
public static final String ELEMENT = "active"; public static final String ELEMENT = "active";
@ -50,7 +50,7 @@ public class ClientStateIndication {
} }
} }
public static class Inactive extends FullStreamElement { public static final class Inactive extends FullStreamElement {
public static final Inactive INSTANCE = new Inactive(); public static final Inactive INSTANCE = new Inactive();
public static final String ELEMENT = "inactive"; public static final String ELEMENT = "inactive";
@ -73,7 +73,7 @@ public class ClientStateIndication {
} }
} }
public static class Feature implements ExtensionElement { public static final class Feature implements ExtensionElement {
public static final Feature INSTANCE = new Feature(); public static final Feature INSTANCE = new Feature();
public static final String ELEMENT = "csi"; public static final String ELEMENT = "csi";

View file

@ -128,7 +128,7 @@ public class MultipleAddresses implements ExtensionElement {
return buf; return buf;
} }
public static class Address implements NamedElement { public static final class Address implements NamedElement {
public static final String ELEMENT = "address"; public static final String ELEMENT = "address";

View file

@ -40,7 +40,7 @@ import org.jivesoftware.smackx.iqprivate.PrivateDataManager;
* *
* @author Alexander Wenckus * @author Alexander Wenckus
*/ */
public class BookmarkManager { public final class BookmarkManager {
private static final Map<XMPPConnection, BookmarkManager> bookmarkManagerMap = new WeakHashMap<XMPPConnection, BookmarkManager>(); private static final Map<XMPPConnection, BookmarkManager> bookmarkManagerMap = new WeakHashMap<XMPPConnection, BookmarkManager>();
static { static {

View file

@ -79,7 +79,7 @@ import org.jxmpp.jid.Jid;
* *
* @author Henning Staib * @author Henning Staib
*/ */
public class InBandBytestreamManager implements BytestreamManager { public final class InBandBytestreamManager implements BytestreamManager {
/** /**
* Stanzas that can be used to encapsulate In-Band Bytestream data packets. * Stanzas that can be used to encapsulate In-Band Bytestream data packets.

View file

@ -68,7 +68,7 @@ import org.jivesoftware.smack.SmackException;
* *
* @author Henning Staib * @author Henning Staib
*/ */
public class Socks5Proxy { public final class Socks5Proxy {
private static final Logger LOGGER = Logger.getLogger(Socks5Proxy.class.getName()); private static final Logger LOGGER = Logger.getLogger(Socks5Proxy.class.getName());
/* SOCKS5 proxy singleton */ /* SOCKS5 proxy singleton */

View file

@ -71,7 +71,7 @@ import java.security.NoSuchAlgorithmException;
* @author Florian Schmaus * @author Florian Schmaus
* @see <a href="http://www.xmpp.org/extensions/xep-0115.html">XEP-0115: Entity Capabilities</a> * @see <a href="http://www.xmpp.org/extensions/xep-0115.html">XEP-0115: Entity Capabilities</a>
*/ */
public class EntityCapsManager extends Manager { public final class EntityCapsManager extends Manager {
private static final Logger LOGGER = Logger.getLogger(EntityCapsManager.class.getName()); private static final Logger LOGGER = Logger.getLogger(EntityCapsManager.class.getName());
public static final String NAMESPACE = CapsExtension.NAMESPACE; public static final String NAMESPACE = CapsExtension.NAMESPACE;

View file

@ -49,7 +49,7 @@ import org.jivesoftware.smackx.disco.ServiceDiscoveryManager;
* @see org.jivesoftware.smackx.chatstates.ChatState * @see org.jivesoftware.smackx.chatstates.ChatState
* @see org.jivesoftware.smackx.chatstates.packet.ChatStateExtension * @see org.jivesoftware.smackx.chatstates.packet.ChatStateExtension
*/ */
public class ChatStateManager extends Manager { public final class ChatStateManager extends Manager {
public static final String NAMESPACE = "http://jabber.org/protocol/chatstates"; public static final String NAMESPACE = "http://jabber.org/protocol/chatstates";
private static final Map<XMPPConnection, ChatStateManager> INSTANCES = private static final Map<XMPPConnection, ChatStateManager> INSTANCES =

View file

@ -60,7 +60,7 @@ import org.jxmpp.jid.Jid;
* *
* @author Gabriel Guardincerri * @author Gabriel Guardincerri
*/ */
public class AdHocCommandManager extends Manager { public final class AdHocCommandManager extends Manager {
public static final String NAMESPACE = "http://jabber.org/protocol/commands"; public static final String NAMESPACE = "http://jabber.org/protocol/commands";
private static final Logger LOGGER = Logger.getLogger(AdHocCommandManager.class.getName()); private static final Logger LOGGER = Logger.getLogger(AdHocCommandManager.class.getName());

View file

@ -24,7 +24,7 @@ import org.jivesoftware.smackx.delay.DelayInformationManager;
/** /**
* Filters stanza with delay information, ie. stanzas that got delayed for some reason * Filters stanza with delay information, ie. stanzas that got delayed for some reason
*/ */
public class DelayedStanzaFilter implements StanzaFilter { public final class DelayedStanzaFilter implements StanzaFilter {
public static final StanzaFilter INSTANCE = new DelayedStanzaFilter(); public static final StanzaFilter INSTANCE = new DelayedStanzaFilter();

View file

@ -63,7 +63,7 @@ import java.util.logging.Logger;
* *
* @author Gaston Dombiak * @author Gaston Dombiak
*/ */
public class ServiceDiscoveryManager extends Manager { public final class ServiceDiscoveryManager extends Manager {
private static final Logger LOGGER = Logger.getLogger(ServiceDiscoveryManager.class.getName()); private static final Logger LOGGER = Logger.getLogger(ServiceDiscoveryManager.class.getName());

View file

@ -43,7 +43,7 @@ import java.util.concurrent.CopyOnWriteArrayList;
* @author Alexander Wenckus * @author Alexander Wenckus
* *
*/ */
public class FileTransferManager extends Manager { public final class FileTransferManager extends Manager {
private static final Map<XMPPConnection, FileTransferManager> INSTANCES = new WeakHashMap<XMPPConnection, FileTransferManager>(); private static final Map<XMPPConnection, FileTransferManager> INSTANCES = new WeakHashMap<XMPPConnection, FileTransferManager>();

View file

@ -52,7 +52,7 @@ import org.jxmpp.jid.Jid;
* @author Alexander Wenckus * @author Alexander Wenckus
* @see <a href="http://xmpp.org/extensions/xep-0096.html">XEP-0096: SI File Transfer</a> * @see <a href="http://xmpp.org/extensions/xep-0096.html">XEP-0096: SI File Transfer</a>
*/ */
public class FileTransferNegotiator extends Manager { public final class FileTransferNegotiator extends Manager {
public static final String SI_NAMESPACE = "http://jabber.org/protocol/si"; public static final String SI_NAMESPACE = "http://jabber.org/protocol/si";
public static final String SI_PROFILE_FILE_TRANSFER_NAMESPACE = "http://jabber.org/protocol/si/profile/file-transfer"; public static final String SI_PROFILE_FILE_TRANSFER_NAMESPACE = "http://jabber.org/protocol/si/profile/file-transfer";

View file

@ -105,7 +105,7 @@ public class IBBTransferNegotiator extends StreamNegotiator {
/** /**
* Derive from InBandBytestreamRequest to access protected constructor. * Derive from InBandBytestreamRequest to access protected constructor.
*/ */
private static class ByteStreamRequest extends InBandBytestreamRequest { private static final class ByteStreamRequest extends InBandBytestreamRequest {
private ByteStreamRequest(InBandBytestreamManager manager, Open byteStreamRequest) { private ByteStreamRequest(InBandBytestreamManager manager, Open byteStreamRequest) {
super(manager, byteStreamRequest); super(manager, byteStreamRequest);

View file

@ -119,7 +119,7 @@ public class Socks5TransferNegotiator extends StreamNegotiator {
/** /**
* Derive from Socks5BytestreamRequest to access protected constructor. * Derive from Socks5BytestreamRequest to access protected constructor.
*/ */
private static class ByteStreamRequest extends Socks5BytestreamRequest { private static final class ByteStreamRequest extends Socks5BytestreamRequest {
private ByteStreamRequest(Socks5BytestreamManager manager, Bytestream byteStreamRequest) { private ByteStreamRequest(Socks5BytestreamManager manager, Bytestream byteStreamRequest) {
super(manager, byteStreamRequest); super(manager, byteStreamRequest);

View file

@ -28,7 +28,7 @@ import org.jivesoftware.smack.packet.Message;
import org.jivesoftware.smackx.geoloc.packet.GeoLocation; import org.jivesoftware.smackx.geoloc.packet.GeoLocation;
import org.jxmpp.jid.Jid; import org.jxmpp.jid.Jid;
public class GeoLocationManager extends Manager { public final class GeoLocationManager extends Manager {
private static final Map<XMPPConnection, GeoLocationManager> INSTANCES = new WeakHashMap<XMPPConnection, GeoLocationManager>(); private static final Map<XMPPConnection, GeoLocationManager> INSTANCES = new WeakHashMap<XMPPConnection, GeoLocationManager>();

View file

@ -33,7 +33,7 @@ import org.jivesoftware.smack.util.XmlStringBuilder;
* @see <a href="http://www.xmpp.org/extensions/xep-0080.html">XEP-0080</a> * @see <a href="http://www.xmpp.org/extensions/xep-0080.html">XEP-0080</a>
* @author Ishan Khanna * @author Ishan Khanna
*/ */
public class GeoLocation implements Serializable, ExtensionElement { public final class GeoLocation implements Serializable, ExtensionElement {
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
public static final String NAMESPACE = "http://jabber.org/protocol/geoloc"; public static final String NAMESPACE = "http://jabber.org/protocol/geoloc";

View file

@ -90,7 +90,7 @@ import org.jxmpp.jid.Jid;
* Activity</a> * Activity</a>
*/ */
public class LastActivityManager extends Manager { public final class LastActivityManager extends Manager {
private static final Map<XMPPConnection, LastActivityManager> instances = new WeakHashMap<XMPPConnection, LastActivityManager>(); private static final Map<XMPPConnection, LastActivityManager> instances = new WeakHashMap<XMPPConnection, LastActivityManager>();
// private static final PacketFilter IQ_GET_LAST_FILTER = new AndFilter(IQTypeFilter.GET, // private static final PacketFilter IQ_GET_LAST_FILTER = new AndFilter(IQTypeFilter.GET,
// new StanzaTypeFilter(LastActivity.class)); // new StanzaTypeFilter(LastActivity.class));

View file

@ -59,7 +59,7 @@ import java.util.WeakHashMap;
* *
* @author Matt Tucker * @author Matt Tucker
*/ */
public class PrivateDataManager extends Manager { public final class PrivateDataManager extends Manager {
private static final Map<XMPPConnection, PrivateDataManager> instances = new WeakHashMap<XMPPConnection, PrivateDataManager>(); private static final Map<XMPPConnection, PrivateDataManager> instances = new WeakHashMap<XMPPConnection, PrivateDataManager>();
public static synchronized PrivateDataManager getInstanceFor(XMPPConnection connection) { public static synchronized PrivateDataManager getInstanceFor(XMPPConnection connection) {

View file

@ -41,7 +41,7 @@ import org.jivesoftware.smackx.iqregister.packet.Registration;
* *
* @author Matt Tucker * @author Matt Tucker
*/ */
public class AccountManager extends Manager { public final class AccountManager extends Manager {
private static final Logger LOGGER = Logger.getLogger(AccountManager.class.getName()); private static final Logger LOGGER = Logger.getLogger(AccountManager.class.getName());

View file

@ -100,7 +100,7 @@ public class Registration extends IQ {
return xml; return xml;
} }
public static class Feature implements ExtensionElement { public static final class Feature implements ExtensionElement {
public static final String ELEMENT = "register"; public static final String ELEMENT = "register";
public static final String NAMESPACE = "http://jabber.org/features/iq-register"; public static final String NAMESPACE = "http://jabber.org/features/iq-register";

View file

@ -53,7 +53,7 @@ import org.jxmpp.jid.Jid;
* *
* @author Georg Lukas * @author Georg Lukas
*/ */
public class VersionManager extends Manager { public final class VersionManager extends Manager {
private static final Map<XMPPConnection, VersionManager> INSTANCES = new WeakHashMap<XMPPConnection, VersionManager>(); private static final Map<XMPPConnection, VersionManager> INSTANCES = new WeakHashMap<XMPPConnection, VersionManager>();
private static Version defaultVersion; private static Version defaultVersion;

View file

@ -55,7 +55,7 @@ import org.jxmpp.jid.DomainBareJid;
import org.jxmpp.jid.Jid; import org.jxmpp.jid.Jid;
import org.jxmpp.jid.JidWithLocalpart; import org.jxmpp.jid.JidWithLocalpart;
public class MultiUserChatManager extends Manager { public final class MultiUserChatManager extends Manager {
private final static String DISCO_NODE = MUCInitialPresence.NAMESPACE + "#rooms"; private final static String DISCO_NODE = MUCInitialPresence.NAMESPACE + "#rooms";
private static final Logger LOGGER = Logger.getLogger(MultiUserChatManager.class.getName()); private static final Logger LOGGER = Logger.getLogger(MultiUserChatManager.class.getName());

View file

@ -413,7 +413,7 @@ public class MUCUser implements ExtensionElement {
* *
* @author Gaston Dombiak * @author Gaston Dombiak
*/ */
public static class Status implements NamedElement { public static final class Status implements NamedElement {
public static final String ELEMENT = "status"; public static final String ELEMENT = "status";
private static final Map<Integer, Status> statusMap = new HashMap<Integer, Status>(8); private static final Map<Integer, Status> statusMap = new HashMap<Integer, Status>(8);

View file

@ -60,7 +60,7 @@ import org.jxmpp.jid.Jid;
* @author Florian Schmaus * @author Florian Schmaus
* @see <a href="http://www.xmpp.org/extensions/xep-0199.html">XEP-0199:XMPP Ping</a> * @see <a href="http://www.xmpp.org/extensions/xep-0199.html">XEP-0199:XMPP Ping</a>
*/ */
public class PingManager extends Manager { public final class PingManager extends Manager {
private static final Logger LOGGER = Logger.getLogger(PingManager.class.getName()); private static final Logger LOGGER = Logger.getLogger(PingManager.class.getName());
private static final Map<XMPPConnection, PingManager> INSTANCES = new WeakHashMap<XMPPConnection, PingManager>(); private static final Map<XMPPConnection, PingManager> INSTANCES = new WeakHashMap<XMPPConnection, PingManager>();

View file

@ -62,7 +62,7 @@ import org.jivesoftware.smackx.privacy.packet.PrivacyItem;
* @author Francisco Vives * @author Francisco Vives
* @see <a href="http://xmpp.org/extensions/xep-0016.html">XEP-16: Privacy Lists</a> * @see <a href="http://xmpp.org/extensions/xep-0016.html">XEP-16: Privacy Lists</a>
*/ */
public class PrivacyListManager extends Manager { public final class PrivacyListManager extends Manager {
public static final String NAMESPACE = Privacy.NAMESPACE; public static final String NAMESPACE = Privacy.NAMESPACE;
public static final StanzaFilter PRIVACY_FILTER = new StanzaTypeFilter(Privacy.class); public static final StanzaFilter PRIVACY_FILTER = new StanzaTypeFilter(Privacy.class);

View file

@ -20,7 +20,7 @@ import org.jivesoftware.smack.filter.FlexibleStanzaTypeFilter;
import org.jivesoftware.smack.packet.IQ.Type; import org.jivesoftware.smack.packet.IQ.Type;
import org.jivesoftware.smackx.privacy.packet.Privacy; import org.jivesoftware.smackx.privacy.packet.Privacy;
public class SetActiveListFilter extends FlexibleStanzaTypeFilter<Privacy> { public final class SetActiveListFilter extends FlexibleStanzaTypeFilter<Privacy> {
public static final SetActiveListFilter INSTANCE = new SetActiveListFilter(); public static final SetActiveListFilter INSTANCE = new SetActiveListFilter();

View file

@ -20,7 +20,7 @@ import org.jivesoftware.smack.filter.FlexibleStanzaTypeFilter;
import org.jivesoftware.smack.packet.IQ.Type; import org.jivesoftware.smack.packet.IQ.Type;
import org.jivesoftware.smackx.privacy.packet.Privacy; import org.jivesoftware.smackx.privacy.packet.Privacy;
public class SetDefaultListFilter extends FlexibleStanzaTypeFilter<Privacy> { public final class SetDefaultListFilter extends FlexibleStanzaTypeFilter<Privacy> {
public static final SetDefaultListFilter INSTANCE = new SetDefaultListFilter(); public static final SetDefaultListFilter INSTANCE = new SetDefaultListFilter();

View file

@ -66,7 +66,7 @@ import org.jxmpp.jid.Jid;
* @author Georg Lukas * @author Georg Lukas
* @see <a href="http://xmpp.org/extensions/xep-0184.html">XEP-0184: Message Delivery Receipts</a> * @see <a href="http://xmpp.org/extensions/xep-0184.html">XEP-0184: Message Delivery Receipts</a>
*/ */
public class DeliveryReceiptManager extends Manager { public final class DeliveryReceiptManager extends Manager {
private static final StanzaFilter MESSAGES_WITH_DEVLIERY_RECEIPT_REQUEST = new AndFilter(StanzaTypeFilter.MESSAGE, private static final StanzaFilter MESSAGES_WITH_DEVLIERY_RECEIPT_REQUEST = new AndFilter(StanzaTypeFilter.MESSAGE,
new StanzaExtensionFilter(new DeliveryReceiptRequest())); new StanzaExtensionFilter(new DeliveryReceiptRequest()));

View file

@ -36,7 +36,7 @@ import org.jivesoftware.smackx.disco.ServiceDiscoveryManager;
import org.jivesoftware.smackx.time.packet.Time; import org.jivesoftware.smackx.time.packet.Time;
import org.jxmpp.jid.Jid; import org.jxmpp.jid.Jid;
public class EntityTimeManager extends Manager { public final class EntityTimeManager extends Manager {
private static final Map<XMPPConnection, EntityTimeManager> INSTANCES = new WeakHashMap<XMPPConnection, EntityTimeManager>(); private static final Map<XMPPConnection, EntityTimeManager> INSTANCES = new WeakHashMap<XMPPConnection, EntityTimeManager>();

View file

@ -33,7 +33,7 @@ import org.jivesoftware.smackx.vcardtemp.packet.VCard;
import org.jxmpp.jid.BareJid; import org.jxmpp.jid.BareJid;
import org.jxmpp.jid.Jid; import org.jxmpp.jid.Jid;
public class VCardManager extends Manager { public final class VCardManager extends Manager {
public static final String NAMESPACE = VCard.NAMESPACE; public static final String NAMESPACE = VCard.NAMESPACE;
public static final String ELEMENT = VCard.ELEMENT; public static final String ELEMENT = VCard.ELEMENT;

View file

@ -30,7 +30,7 @@ import org.jivesoftware.smackx.disco.ServiceDiscoveryManager;
import org.jivesoftware.smackx.xdata.packet.DataForm; import org.jivesoftware.smackx.xdata.packet.DataForm;
import org.jxmpp.jid.Jid; import org.jxmpp.jid.Jid;
public class XDataManager extends Manager { public final class XDataManager extends Manager {
/** /**
* The value of {@link DataForm#NAMESPACE}. * The value of {@link DataForm#NAMESPACE}.

View file

@ -37,7 +37,7 @@ import org.jivesoftware.smack.SmackException;
* *
* @author Henning Staib * @author Henning Staib
*/ */
public class Socks5TestProxy { public final class Socks5TestProxy {
private static final Logger LOGGER = Logger.getLogger(Socks5TestProxy.class.getName()); private static final Logger LOGGER = Logger.getLogger(Socks5TestProxy.class.getName());
/* SOCKS5 proxy singleton */ /* SOCKS5 proxy singleton */

View file

@ -53,7 +53,7 @@ import org.jxmpp.jid.JidWithLocalpart;
* *
* @author Alexander Wenckus * @author Alexander Wenckus
*/ */
public class ChatManager extends Manager{ public final class ChatManager extends Manager{
private static final Logger LOGGER = Logger.getLogger(ChatManager.class.getName()); private static final Logger LOGGER = Logger.getLogger(ChatManager.class.getName());

View file

@ -82,7 +82,7 @@ import org.jxmpp.jid.parts.Resourcepart;
* @author Matt Tucker * @author Matt Tucker
* @see #getInstanceFor(XMPPConnection) * @see #getInstanceFor(XMPPConnection)
*/ */
public class Roster extends Manager { public final class Roster extends Manager {
private static final Logger LOGGER = Logger.getLogger(Roster.class.getName()); private static final Logger LOGGER = Logger.getLogger(Roster.class.getName());
@ -1459,7 +1459,7 @@ public class Roster extends Manager {
/** /**
* Listens for all roster pushes and processes them. * Listens for all roster pushes and processes them.
*/ */
private class RosterPushListener extends AbstractIqRequestHandler { private final class RosterPushListener extends AbstractIqRequestHandler {
private RosterPushListener() { private RosterPushListener() {
super(RosterPacket.ELEMENT, RosterPacket.NAMESPACE, Type.set, Mode.sync); super(RosterPacket.ELEMENT, RosterPacket.NAMESPACE, Type.set, Mode.sync);

View file

@ -19,7 +19,7 @@ package org.jivesoftware.smack.roster.packet;
import org.jivesoftware.smack.packet.ExtensionElement; import org.jivesoftware.smack.packet.ExtensionElement;
import org.jivesoftware.smack.util.XmlStringBuilder; import org.jivesoftware.smack.util.XmlStringBuilder;
public class RosterVer implements ExtensionElement { public final class RosterVer implements ExtensionElement {
public static final String ELEMENT = "ver"; public static final String ELEMENT = "ver";
public static final String NAMESPACE = "urn:xmpp:features:rosterver"; public static final String NAMESPACE = "urn:xmpp:features:rosterver";

View file

@ -19,7 +19,7 @@ package org.jivesoftware.smack.roster.packet;
import org.jivesoftware.smack.packet.ExtensionElement; import org.jivesoftware.smack.packet.ExtensionElement;
import org.jivesoftware.smack.util.XmlStringBuilder; import org.jivesoftware.smack.util.XmlStringBuilder;
public class SubscriptionPreApproval implements ExtensionElement { public final class SubscriptionPreApproval implements ExtensionElement {
public static final String ELEMENT = "sub"; public static final String ELEMENT = "sub";
public static final String NAMESPACE = "urn:xmpp:features:pre-approval"; public static final String NAMESPACE = "urn:xmpp:features:pre-approval";

View file

@ -44,7 +44,7 @@ import org.xmlpull.v1.XmlPullParserException;
* @author Lars Noschinski * @author Lars Noschinski
* @author Fabian Schuetz * @author Fabian Schuetz
*/ */
public class DirectoryRosterStore implements RosterStore { public final class DirectoryRosterStore implements RosterStore {
private final File fileDir; private final File fileDir;

View file

@ -33,7 +33,7 @@ import org.jxmpp.jid.DomainBareJid;
import org.jxmpp.jid.impl.JidCreate; import org.jxmpp.jid.impl.JidCreate;
import org.jxmpp.stringprep.XmppStringprepException; import org.jxmpp.stringprep.XmppStringprepException;
public class Configuration { public final class Configuration {
public final DomainBareJid service; public final DomainBareJid service;
@ -92,7 +92,7 @@ public class Configuration {
return new Builder(); return new Builder();
} }
public static class Builder { public static final class Builder {
private DomainBareJid service; private DomainBareJid service;

View file

@ -55,7 +55,7 @@ public class IntTestUtil {
return new UsernameAndPassword(username, password); return new UsernameAndPassword(username, password);
} }
public static class UsernameAndPassword { public static final class UsernameAndPassword {
public final String username; public final String username;
public final String password; public final String password;

View file

@ -595,7 +595,7 @@ public class SmackIntegrationTestFramework {
return (Exception) e; return (Exception) e;
} }
public static class TestRunResult { public static final class TestRunResult {
public final String testRunId = StringUtils.randomString(5); public final String testRunId = StringUtils.randomString(5);
private final List<SuccessfulTest> successfulTests = Collections.synchronizedList(new LinkedList<SuccessfulTest>()); private final List<SuccessfulTest> successfulTests = Collections.synchronizedList(new LinkedList<SuccessfulTest>());
private final List<FailedTest> failedIntegrationTests = Collections.synchronizedList(new LinkedList<FailedTest>()); private final List<FailedTest> failedIntegrationTests = Collections.synchronizedList(new LinkedList<FailedTest>());

View file

@ -29,7 +29,7 @@ import java.util.logging.Logger;
* @author rob@iharder.net * @author rob@iharder.net
* @version 2.2.1 * @version 2.2.1
*/ */
public class Base64 public final class Base64
{ {
private static final Logger LOGGER = Logger.getLogger(Base64.class.getName()); private static final Logger LOGGER = Logger.getLogger(Base64.class.getName());

View file

@ -24,7 +24,7 @@ import org.jivesoftware.smack.util.StringUtils;
* A Base 64 encoding implementation. * A Base 64 encoding implementation.
* @author Florian Schmaus * @author Florian Schmaus
*/ */
public class Java7Base64Encoder implements org.jivesoftware.smack.util.stringencoder.Base64.Encoder { public final class Java7Base64Encoder implements org.jivesoftware.smack.util.stringencoder.Base64.Encoder {
private static Java7Base64Encoder instance = new Java7Base64Encoder(); private static Java7Base64Encoder instance = new Java7Base64Encoder();

View file

@ -30,7 +30,7 @@ import org.jivesoftware.smack.util.stringencoder.StringEncoder;
* *
* @author Robin Collier * @author Robin Collier
*/ */
public class Java7Base64UrlSafeEncoder implements StringEncoder { public final class Java7Base64UrlSafeEncoder implements StringEncoder {
private static Java7Base64UrlSafeEncoder instance = new Java7Base64UrlSafeEncoder(); private static Java7Base64UrlSafeEncoder instance = new Java7Base64UrlSafeEncoder();

View file

@ -170,7 +170,7 @@ public class WorkgroupQueue {
* chat requests. * chat requests.
* </ul> * </ul>
*/ */
public static class Status { public static final class Status {
/** /**
* The queue is active and accepting new chat requests. * The queue is active and accepting new chat requests.

View file

@ -37,7 +37,7 @@ import java.util.logging.Logger;
* Queue details stanza(/packet) extension, which contains details about the users * Queue details stanza(/packet) extension, which contains details about the users
* currently in a queue. * currently in a queue.
*/ */
public class QueueDetails implements ExtensionElement { public final class QueueDetails implements ExtensionElement {
private static final Logger LOGGER = Logger.getLogger(QueueDetails.class.getName()); private static final Logger LOGGER = Logger.getLogger(QueueDetails.class.getName());
/** /**

View file

@ -48,7 +48,7 @@ import org.jxmpp.jid.Jid;
* @author Gaston Dombiak * @author Gaston Dombiak
* @see <a href="http://xmpp.org/extensions/xep-0022.html">XEP-22: Message Events</a> * @see <a href="http://xmpp.org/extensions/xep-0022.html">XEP-22: Message Events</a>
*/ */
public class MessageEventManager extends Manager { public final class MessageEventManager extends Manager {
private static final Logger LOGGER = Logger.getLogger(MessageEventManager.class.getName()); private static final Logger LOGGER = Logger.getLogger(MessageEventManager.class.getName());
private static final Map<XMPPConnection, MessageEventManager> INSTANCES = new WeakHashMap<>(); private static final Map<XMPPConnection, MessageEventManager> INSTANCES = new WeakHashMap<>();

View file

@ -24,7 +24,7 @@ import org.jivesoftware.smack.util.XmlStringBuilder;
public class StreamManagement { public class StreamManagement {
public static final String NAMESPACE = "urn:xmpp:sm:3"; public static final String NAMESPACE = "urn:xmpp:sm:3";
public static class StreamManagementFeature implements ExtensionElement { public static final class StreamManagementFeature implements ExtensionElement {
public static final String ELEMENT = "sm"; public static final String ELEMENT = "sm";
public static final StreamManagementFeature INSTANCE = new StreamManagementFeature(); public static final StreamManagementFeature INSTANCE = new StreamManagementFeature();
@ -320,7 +320,7 @@ public class StreamManagement {
} }
} }
public static class AckRequest extends FullStreamElement { public static final class AckRequest extends FullStreamElement {
public static final String ELEMENT = "r"; public static final String ELEMENT = "r";
public static final AckRequest INSTANCE = new AckRequest(); public static final AckRequest INSTANCE = new AckRequest();

View file

@ -20,7 +20,7 @@ import org.jivesoftware.smack.filter.StanzaFilter;
import org.jivesoftware.smack.packet.Message; import org.jivesoftware.smack.packet.Message;
import org.jivesoftware.smack.packet.Stanza; import org.jivesoftware.smack.packet.Stanza;
public class ForEveryMessage implements StanzaFilter { public final class ForEveryMessage implements StanzaFilter {
public static final ForEveryMessage INSTANCE = new ForEveryMessage(); public static final ForEveryMessage INSTANCE = new ForEveryMessage();

View file

@ -19,7 +19,7 @@ package org.jivesoftware.smack.sm.predicates;
import org.jivesoftware.smack.filter.StanzaFilter; import org.jivesoftware.smack.filter.StanzaFilter;
import org.jivesoftware.smack.packet.Stanza; import org.jivesoftware.smack.packet.Stanza;
public class ForEveryStanza implements StanzaFilter { public final class ForEveryStanza implements StanzaFilter {
public static final ForEveryStanza INSTANCE = new ForEveryStanza(); public static final ForEveryStanza INSTANCE = new ForEveryStanza();

View file

@ -21,7 +21,7 @@ import org.jivesoftware.smack.packet.Stanza;
import org.jivesoftware.smack.tcp.XMPPTCPConnection; import org.jivesoftware.smack.tcp.XMPPTCPConnection;
import org.jivesoftware.smack.util.StringUtils; import org.jivesoftware.smack.util.StringUtils;
public class OnceForThisStanza implements StanzaFilter { public final class OnceForThisStanza implements StanzaFilter {
private final String id; private final String id;
private final XMPPTCPConnection connection; private final XMPPTCPConnection connection;

View file

@ -33,7 +33,7 @@ import org.jivesoftware.smack.ConnectionConfiguration;
* } * }
* </pre> * </pre>
*/ */
public class XMPPTCPConnectionConfiguration extends ConnectionConfiguration { public final class XMPPTCPConnectionConfiguration extends ConnectionConfiguration {
/** /**
* The default connect timeout in milliseconds. Preinitialized with 30000 (30 seconds). If this value is changed, * The default connect timeout in milliseconds. Preinitialized with 30000 (30 seconds). If this value is changed,
@ -84,7 +84,7 @@ public class XMPPTCPConnectionConfiguration extends ConnectionConfiguration {
* A configuration builder for XMPP connections over TCP. Use {@link XMPPTCPConnectionConfiguration#builder()} to * A configuration builder for XMPP connections over TCP. Use {@link XMPPTCPConnectionConfiguration#builder()} to
* obtain a new instance and {@link #build} to build the configuration. * obtain a new instance and {@link #build} to build the configuration.
*/ */
public static class Builder extends ConnectionConfiguration.Builder<Builder, XMPPTCPConnectionConfiguration> { public static final class Builder extends ConnectionConfiguration.Builder<Builder, XMPPTCPConnectionConfiguration> {
private boolean compressionEnabled = false; private boolean compressionEnabled = false;
private int connectTimeout = DEFAULT_CONNECT_TIMEOUT; private int connectTimeout = DEFAULT_CONNECT_TIMEOUT;