public final class InBandByteStreamManager extends ByteStreamManager
A manager for XEP-0047: In-Band Bytestreams. IBB streams use the same transport as XMPP, i.e. the same TCP or BOSH connection.
To initiate an IBB session with another entity, use initiateSession(Jid, String, int)
.
This class is thread-safe.
Modifier and Type | Method and Description |
---|---|
InBandByteStream.Open.StanzaType |
getStanzaType()
Gets the stanza type.
|
AsyncResult<ByteStreamSession> |
initiateSession(Jid receiver,
java.lang.String sessionId,
int blockSize)
Initiates an in-band byte stream session.
|
void |
setStanzaType(InBandByteStream.Open.StanzaType stanzaType)
Sets the stanza type, which is used to send data chunks.
|
addByteStreamListener, removeByteStreamListener
isEnabled, setEnabled
public final AsyncResult<ByteStreamSession> initiateSession(Jid receiver, java.lang.String sessionId, int blockSize)
Initiates an in-band byte stream session.
receiver
- The receiver.sessionId
- The session id.blockSize
- The block size.public final void setStanzaType(InBandByteStream.Open.StanzaType stanzaType)
Sets the stanza type, which is used to send data chunks. It is recommended to leave this on the default (InBandByteStream.Open.StanzaType.IQ
).
stanzaType
- The stanza type.public final InBandByteStream.Open.StanzaType getStanzaType()
Gets the stanza type.
Copyright © 2014–2019 XMPP.rocks. All rights reserved.