CarrotChat v2.8.60.240131版本的 MD5 值为:2baf8b9f31830b86b5c5a85ae6b47e05
以下内容为反编译后的 DataListener.java 源代码,内容仅作参考
package org.jivesoftware.smackx.bytestreams.ibb;
import org.jivesoftware.smack.SmackException;
import org.jivesoftware.smack.iqrequest.AbstractIqRequestHandler;
import org.jivesoftware.smack.iqrequest.IQRequestHandler;
import org.jivesoftware.smack.packet.IQ;
import org.jivesoftware.smackx.bytestreams.ibb.packet.Data;
public class DataListener extends AbstractIqRequestHandler {
private final InBandBytestreamManager manager;
public DataListener(InBandBytestreamManager inBandBytestreamManager) {
super("data", "http://jabber.org/protocol/ibb", IQ.Type.set, IQRequestHandler.Mode.async);
this.manager = inBandBytestreamManager;
}
@Override
public IQ handleIQRequest(IQ iq) {
Data data = (Data) iq;
InBandBytestreamSession inBandBytestreamSession = this.manager.getSessions().get(data.getDataPacketExtension().getSessionID());
try {
if (inBandBytestreamSession == null) {
this.manager.replyItemNotFoundPacket(data);
} else {
inBandBytestreamSession.processIQPacket(data);
}
} catch (InterruptedException | SmackException.NotConnectedException | SmackException.NotLoggedInException unused) {
}
return null;
}
}