public final class StreamInitiationManager extends ExtensionManager implements FileTransferNegotiator
features, xmppSession| Modifier and Type | Method and Description |
|---|---|
FileTransfer |
accept(rocks.xmpp.core.stanza.model.client.IQ iq,
String sessionId,
FileTransferOffer fileTransferOffer,
Object protocol,
OutputStream outputStream) |
OutputStream |
initiateStream(rocks.xmpp.core.Jid receiver,
SIFileTransferOffer profile,
String mimeType,
long timeout)
Initiates a stream with another entity.
|
void |
reject(rocks.xmpp.core.stanza.model.client.IQ iq) |
setEnabledpublic OutputStream initiateStream(rocks.xmpp.core.Jid receiver, SIFileTransferOffer profile, String mimeType, long timeout) throws rocks.xmpp.core.XmppException, IOException
receiver - The receiver, i.e. the XMPP entity you want to negotiate a stream.profile - The profile. Currently there's only the SIFileTransferOffer profile.mimeType - The mime type of the stream.timeout - The timeout, which wait until the stream has been negotiated.rocks.xmpp.core.stanza.model.StanzaException - If the entity returned a stanza error.NoResponseException - If the entity did not respond.IOException - If an I/O error occurred during byte session establishment.rocks.xmpp.core.XmppExceptionpublic FileTransfer accept(rocks.xmpp.core.stanza.model.client.IQ iq, String sessionId, FileTransferOffer fileTransferOffer, Object protocol, OutputStream outputStream) throws IOException
accept in interface FileTransferNegotiatorIOExceptionpublic void reject(rocks.xmpp.core.stanza.model.client.IQ iq)
reject in interface FileTransferNegotiatorCopyright © 2014 XMPP.rocks. All rights reserved.