mirror of
https://github.com/vanitasvitae/Smack.git
synced 2025-09-10 17:49:38 +02:00
Merged the 3.2 branch back into trunk.
git-svn-id: http://svn.igniterealtime.org/svn/repos/smack/trunk@12588 b35dd754-fafc-0310-a699-88a17e54d16e
This commit is contained in:
commit
3f89df061d
16 changed files with 383 additions and 240 deletions
|
@ -115,7 +115,7 @@ public class ServiceDiscoveryManager {
|
|||
/**
|
||||
* Returns the type of client that will be returned when asked for the client identity in a
|
||||
* disco request. The valid types are defined by the category client. Follow this link to learn
|
||||
* the possible types: <a href="http://www.jabber.org/registrar/disco-categories.html#client">Jabber::Registrar</a>.
|
||||
* the possible types: <a href="http://xmpp.org/registrar/disco-categories.html#client">Jabber::Registrar</a>.
|
||||
*
|
||||
* @return the type of client that will be returned when asked for the client identity in a
|
||||
* disco request.
|
||||
|
@ -127,7 +127,7 @@ public class ServiceDiscoveryManager {
|
|||
/**
|
||||
* Sets the type of client that will be returned when asked for the client identity in a
|
||||
* disco request. The valid types are defined by the category client. Follow this link to learn
|
||||
* the possible types: <a href="http://www.jabber.org/registrar/disco-categories.html#client">Jabber::Registrar</a>.
|
||||
* the possible types: <a href="http://xmpp.org/registrar/disco-categories.html#client">Jabber::Registrar</a>.
|
||||
*
|
||||
* @param type the type of client that will be returned when asked for the client identity in a
|
||||
* disco request.
|
||||
|
|
|
@ -131,7 +131,7 @@ public class XHTMLText {
|
|||
*
|
||||
*/
|
||||
public void appendBrTag() {
|
||||
text.append("<br>");
|
||||
text.append("<br/>");
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -326,10 +326,7 @@ public class EnhancedDebugger implements SmackDebugger {
|
|||
|
||||
@Override
|
||||
public void actionPerformed(ActionEvent e) {
|
||||
for(int i=0; i< messagesTable.getRowCount();i++)
|
||||
{
|
||||
messagesTable.removeRow(i);
|
||||
}
|
||||
messagesTable.setRowCount(0);
|
||||
|
||||
}
|
||||
});
|
||||
|
|
|
@ -324,7 +324,8 @@ public class FileTransferNegotiator {
|
|||
throw new XMPPException(error.getMessage(), error);
|
||||
}
|
||||
|
||||
if (isByteStream && isIBB && field.getType().equals(FormField.TYPE_LIST_MULTI)) {
|
||||
//if (isByteStream && isIBB && field.getType().equals(FormField.TYPE_LIST_MULTI)) {
|
||||
if (isByteStream && isIBB) {
|
||||
return new FaultTolerantNegotiator(connection,
|
||||
byteStreamTransferManager,
|
||||
inbandTransferManager);
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
|
||||
package org.jivesoftware.smackx.muc;
|
||||
|
||||
import org.jivesoftware.smack.SmackConfiguration;
|
||||
import org.jivesoftware.smack.packet.Packet;
|
||||
|
||||
import java.util.LinkedList;
|
||||
|
@ -38,7 +39,7 @@ class ConnectionDetachedPacketCollector {
|
|||
* reached, older packets will be automatically dropped from the queue as
|
||||
* new packets are added.
|
||||
*/
|
||||
private static final int MAX_PACKETS = 65536;
|
||||
private int maxPackets = SmackConfiguration.getPacketCollectorSize();
|
||||
|
||||
private LinkedList<Packet> resultQueue;
|
||||
|
||||
|
@ -50,6 +51,15 @@ class ConnectionDetachedPacketCollector {
|
|||
this.resultQueue = new LinkedList<Packet>();
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new packet collector. If the packet filter is <tt>null</tt>, then
|
||||
* all packets will match this collector.
|
||||
*/
|
||||
public ConnectionDetachedPacketCollector(int maxSize) {
|
||||
this.resultQueue = new LinkedList<Packet>();
|
||||
maxPackets = maxSize;
|
||||
}
|
||||
|
||||
/**
|
||||
* Polls to see if a packet is currently available and returns it, or
|
||||
* immediately returns <tt>null</tt> if no packets are currently in the
|
||||
|
@ -124,7 +134,7 @@ class ConnectionDetachedPacketCollector {
|
|||
return;
|
||||
}
|
||||
// If the max number of packets has been reached, remove the oldest one.
|
||||
if (resultQueue.size() == MAX_PACKETS) {
|
||||
if (resultQueue.size() == maxPackets) {
|
||||
resultQueue.removeLast();
|
||||
}
|
||||
// Add the new packet.
|
||||
|
|
|
@ -60,7 +60,7 @@ class RoomListenerMultiplexor implements ConnectionListener {
|
|||
*/
|
||||
public static RoomListenerMultiplexor getRoomMultiplexor(Connection conn) {
|
||||
synchronized (monitors) {
|
||||
if (!monitors.containsKey(conn)) {
|
||||
if (!monitors.containsKey(conn) || monitors.get(conn).get() == null) {
|
||||
RoomListenerMultiplexor rm = new RoomListenerMultiplexor(conn, new RoomMultiplexFilter(),
|
||||
new RoomMultiplexListener());
|
||||
|
||||
|
|
|
@ -13,11 +13,10 @@
|
|||
*/
|
||||
package org.jivesoftware.smackx.pubsub;
|
||||
|
||||
import org.jivesoftware.smack.packet.Message;
|
||||
import org.jivesoftware.smack.packet.PacketExtension;
|
||||
import org.jivesoftware.smackx.pubsub.provider.ItemProvider;
|
||||
|
||||
import com.sun.corba.se.impl.protocol.giopmsgheaders.Message;
|
||||
|
||||
/**
|
||||
* This class represents an item that has been, or will be published to a
|
||||
* pubsub node. An <tt>Item</tt> has several properties that are dependent
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue