public class FileTransferManager extends Object implements ContextAware, FileTransferNegotiator.NegotiationFailureHandler, FileTransferNegotiator.NegotiationRejectHandler, FileTransferNegotiator.NegotiationRequestHandler, ConnectionManager.ConnectionEstablishedHandler, Property
Modifier and Type | Class and Description |
---|---|
static interface |
FileTransferManager.FileTransferFailureHandler |
static interface |
FileTransferManager.FileTransferProgressHandler |
static interface |
FileTransferManager.FileTransferRejectedHandler |
static interface |
FileTransferManager.FileTransferRequestHandler |
static interface |
FileTransferManager.FileTransferSuccessHandler |
FileTransferNegotiator.NegotiationFailureHandler.FileTransferNegotiationFailureEvent
FileTransferNegotiator.NegotiationRejectHandler.FileTransferNegotiationRejectEvent
FileTransferNegotiator.NegotiationRequestHandler.FileTransferNegotiationRequestEvent
ConnectionManager.ConnectionEstablishedHandler.ConnectionEstablishedEvent
Constructor and Description |
---|
FileTransferManager() |
Modifier and Type | Method and Description |
---|---|
void |
acceptFile(FileTransfer ft) |
void |
addNegotiator(FileTransferNegotiator negotiator) |
protected static String |
getCapsNode(Presence presence) |
Class<FileTransferManager> |
getPropertyClass()
Method which returns class which implements this interface which
may be used as a key to store instance of this class in JaxmppCore.
|
static void |
initialize(JaxmppCore jaxmpp,
boolean experimental) |
void |
onConnectionEstablished(SessionObject sessionObject,
ConnectionSession connectionSession,
Socket socket) |
void |
onFileTransferNegotiationFailure(SessionObject sessionObject,
FileTransfer fileTransfer) |
void |
onFileTransferNegotiationReject(SessionObject sessionObject,
FileTransfer fileTransfer) |
void |
onFileTransferNegotiationRequest(SessionObject sessionObject,
FileTransfer fileTransfer) |
void |
rejectFile(FileTransfer ft) |
void |
removeNegotiator(FileTransferNegotiator negotiator) |
FileTransfer |
sendFile(JID peer,
File file) |
FileTransfer |
sendFile(JID peer,
String filename,
long fileSize,
InputStream is,
Date lastModified) |
void |
setContext(Context context) |
void |
setJaxmpp(JaxmppCore jaxmpp) |
protected Context context
protected static String getCapsNode(Presence presence) throws XMLException
XMLException
public static void initialize(JaxmppCore jaxmpp, boolean experimental)
public void acceptFile(FileTransfer ft) throws JaxmppException
JaxmppException
public void addNegotiator(FileTransferNegotiator negotiator)
public Class<FileTransferManager> getPropertyClass()
Property
getPropertyClass
in interface Property
public void onConnectionEstablished(SessionObject sessionObject, ConnectionSession connectionSession, Socket socket) throws JaxmppException
onConnectionEstablished
in interface ConnectionManager.ConnectionEstablishedHandler
JaxmppException
public void onFileTransferNegotiationFailure(SessionObject sessionObject, FileTransfer fileTransfer) throws JaxmppException
onFileTransferNegotiationFailure
in interface FileTransferNegotiator.NegotiationFailureHandler
JaxmppException
public void onFileTransferNegotiationReject(SessionObject sessionObject, FileTransfer fileTransfer)
onFileTransferNegotiationReject
in interface FileTransferNegotiator.NegotiationRejectHandler
public void onFileTransferNegotiationRequest(SessionObject sessionObject, FileTransfer fileTransfer)
onFileTransferNegotiationRequest
in interface FileTransferNegotiator.NegotiationRequestHandler
public void rejectFile(FileTransfer ft) throws JaxmppException
JaxmppException
public void removeNegotiator(FileTransferNegotiator negotiator)
public FileTransfer sendFile(JID peer, File file) throws JaxmppException
JaxmppException
public FileTransfer sendFile(JID peer, String filename, long fileSize, InputStream is, Date lastModified) throws JaxmppException
JaxmppException
public void setContext(Context context)
setContext
in interface ContextAware
public void setJaxmpp(JaxmppCore jaxmpp)
Copyright © 2006–2023 Tigase. All rights reserved.