mirror of
https://github.com/vanitasvitae/Smack.git
synced 2025-12-12 05:51:08 +01:00
s/processPacket/processStanza/ s/PacketCollector/StanzaCollector/
This commit is contained in:
parent
9328182912
commit
90a5e289f8
100 changed files with 406 additions and 406 deletions
|
|
@ -426,7 +426,7 @@ public final class InBandBytestreamManager implements BytestreamManager {
|
|||
byteStreamRequest.setTo(targetJID);
|
||||
|
||||
// sending packet will throw exception on timeout or error reply
|
||||
connection.createPacketCollectorAndSend(byteStreamRequest).nextResultOrThrow();
|
||||
connection.createStanzaCollectorAndSend(byteStreamRequest).nextResultOrThrow();
|
||||
|
||||
InBandBytestreamSession inBandBytestreamSession = new InBandBytestreamSession(
|
||||
this.connection, byteStreamRequest, targetJID);
|
||||
|
|
|
|||
|
|
@ -211,7 +211,7 @@ public class InBandBytestreamSession implements BytestreamSession {
|
|||
Close close = new Close(this.byteStreamRequest.getSessionID());
|
||||
close.setTo(this.remoteJID);
|
||||
try {
|
||||
connection.createPacketCollectorAndSend(close).nextResultOrThrow();
|
||||
connection.createStanzaCollectorAndSend(close).nextResultOrThrow();
|
||||
}
|
||||
catch (Exception e) {
|
||||
// Sadly we are unable to use the IOException(Throwable) constructor because this
|
||||
|
|
@ -449,7 +449,7 @@ public class InBandBytestreamSession implements BytestreamSession {
|
|||
|
||||
private long lastSequence = -1;
|
||||
|
||||
public void processPacket(Stanza packet) throws NotConnectedException, InterruptedException {
|
||||
public void processStanza(Stanza packet) throws NotConnectedException, InterruptedException {
|
||||
// get data packet extension
|
||||
DataPacketExtension data = ((Data) packet).getDataPacketExtension();
|
||||
|
||||
|
|
@ -510,7 +510,7 @@ public class InBandBytestreamSession implements BytestreamSession {
|
|||
protected StanzaListener getDataPacketListener() {
|
||||
return new StanzaListener() {
|
||||
|
||||
public void processPacket(Stanza packet) {
|
||||
public void processStanza(Stanza packet) {
|
||||
// get data packet extension
|
||||
DataPacketExtension data = (DataPacketExtension) packet.getExtension(
|
||||
DataPacketExtension.ELEMENT,
|
||||
|
|
@ -781,7 +781,7 @@ public class InBandBytestreamSession implements BytestreamSession {
|
|||
iq.setTo(remoteJID);
|
||||
|
||||
try {
|
||||
connection.createPacketCollectorAndSend(iq).nextResultOrThrow();
|
||||
connection.createStanzaCollectorAndSend(iq).nextResultOrThrow();
|
||||
}
|
||||
catch (Exception e) {
|
||||
// close session unless it is already closed
|
||||
|
|
@ -824,7 +824,7 @@ public class InBandBytestreamSession implements BytestreamSession {
|
|||
* @throws InterruptedException
|
||||
*/
|
||||
public void processIQPacket(Data data) throws NotConnectedException, InterruptedException {
|
||||
inputStream.dataPacketListener.processPacket(data);
|
||||
inputStream.dataPacketListener.processStanza(data);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -464,7 +464,7 @@ public final class Socks5BytestreamManager extends Manager implements Bytestream
|
|||
Bytestream initiation = createBytestreamInitiation(sessionID, targetJID, streamHosts);
|
||||
|
||||
// send initiation packet
|
||||
Stanza response = connection.createPacketCollectorAndSend(initiation).nextResultOrThrow(
|
||||
Stanza response = connection.createStanzaCollectorAndSend(initiation).nextResultOrThrow(
|
||||
getTargetResponseTimeout());
|
||||
|
||||
// extract used stream host from response
|
||||
|
|
@ -590,7 +590,7 @@ public final class Socks5BytestreamManager extends Manager implements Bytestream
|
|||
for (Jid proxy : proxies) {
|
||||
Bytestream streamHostRequest = createStreamHostRequest(proxy);
|
||||
try {
|
||||
Bytestream response = (Bytestream) connection.createPacketCollectorAndSend(
|
||||
Bytestream response = (Bytestream) connection.createStanzaCollectorAndSend(
|
||||
streamHostRequest).nextResultOrThrow();
|
||||
streamHosts.addAll(response.getStreamHosts());
|
||||
}
|
||||
|
|
|
|||
|
|
@ -113,7 +113,7 @@ class Socks5ClientForInitiator extends Socks5Client {
|
|||
private void activate() throws NoResponseException, XMPPErrorException, NotConnectedException, InterruptedException {
|
||||
Bytestream activate = createStreamHostActivation();
|
||||
// if activation fails #nextResultOrThrow() throws an exception
|
||||
connection.get().createPacketCollectorAndSend(activate).nextResultOrThrow();
|
||||
connection.get().createStanzaCollectorAndSend(activate).nextResultOrThrow();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue