1
0
Fork 0
mirror of https://codeberg.org/Mercury-IM/Smack synced 2024-11-27 00:32:07 +01:00

Remove some deprecated code

This commit is contained in:
Florian Schmaus 2014-02-20 16:04:20 +01:00
parent 352c362e90
commit 2241dae16a
2 changed files with 1 additions and 55 deletions

View file

@ -18,7 +18,6 @@
package org.jivesoftware.smack; package org.jivesoftware.smack;
import org.jivesoftware.smack.compression.XMPPInputOutputStream; import org.jivesoftware.smack.compression.XMPPInputOutputStream;
import org.jivesoftware.smack.filter.PacketFilter;
import org.jivesoftware.smack.packet.Packet; import org.jivesoftware.smack.packet.Packet;
import org.jivesoftware.smack.packet.Presence; import org.jivesoftware.smack.packet.Presence;
import org.jivesoftware.smack.packet.XMPPError; import org.jivesoftware.smack.packet.XMPPError;
@ -485,57 +484,6 @@ public class XMPPConnection extends Connection {
packetWriter.sendPacket(packet); packetWriter.sendPacket(packet);
} }
/**
* Registers a packet interceptor with this connection. The interceptor will be
* invoked every time a packet is about to be sent by this connection. Interceptors
* may modify the packet to be sent. A packet filter determines which packets
* will be delivered to the interceptor.
*
* @param packetInterceptor the packet interceptor to notify of packets about to be sent.
* @param packetFilter the packet filter to use.
* @deprecated replaced by {@link Connection#addPacketInterceptor(PacketInterceptor, PacketFilter)}.
*/
public void addPacketWriterInterceptor(PacketInterceptor packetInterceptor,
PacketFilter packetFilter) {
addPacketInterceptor(packetInterceptor, packetFilter);
}
/**
* Removes a packet interceptor.
*
* @param packetInterceptor the packet interceptor to remove.
* @deprecated replaced by {@link Connection#removePacketInterceptor(PacketInterceptor)}.
*/
public void removePacketWriterInterceptor(PacketInterceptor packetInterceptor) {
removePacketInterceptor(packetInterceptor);
}
/**
* Registers a packet listener with this connection. The listener will be
* notified of every packet that this connection sends. A packet filter determines
* which packets will be delivered to the listener. Note that the thread
* that writes packets will be used to invoke the listeners. Therefore, each
* packet listener should complete all operations quickly or use a different
* thread for processing.
*
* @param packetListener the packet listener to notify of sent packets.
* @param packetFilter the packet filter to use.
* @deprecated replaced by {@link #addPacketSendingListener(PacketListener, PacketFilter)}.
*/
public void addPacketWriterListener(PacketListener packetListener, PacketFilter packetFilter) {
addPacketSendingListener(packetListener, packetFilter);
}
/**
* Removes a packet listener for sending packets from this connection.
*
* @param packetListener the packet listener to remove.
* @deprecated replaced by {@link #removePacketSendingListener(PacketListener)}.
*/
public void removePacketWriterListener(PacketListener packetListener) {
removePacketSendingListener(packetListener);
}
private void connectUsingConfiguration(ConnectionConfiguration config) throws XMPPException { private void connectUsingConfiguration(ConnectionConfiguration config) throws XMPPException {
XMPPException exception = null; XMPPException exception = null;
Iterator<HostAddress> it = config.getHostAddresses().iterator(); Iterator<HostAddress> it = config.getHostAddresses().iterator();

View file

@ -91,11 +91,9 @@ public class ServiceDiscoveryManager {
* service manager will respond to any service discovery request that the connection may * service manager will respond to any service discovery request that the connection may
* receive. * receive.
* *
* @deprecated use {@link #getInstanceFor(connection)} instead
* @param connection the connection to which a ServiceDiscoveryManager is going to be created. * @param connection the connection to which a ServiceDiscoveryManager is going to be created.
*/ */
@Deprecated private ServiceDiscoveryManager(Connection connection) {
public ServiceDiscoveryManager(Connection connection) {
this.connection = new WeakReference<Connection>(connection); this.connection = new WeakReference<Connection>(connection);
// Register the new instance and associate it with the connection // Register the new instance and associate it with the connection