Interface FileTransferManager

  • All Superinterfaces:
    All Known Implementing Classes:

    public interface FileTransferManager
    extends Module
    Manages all file transfer currently happening originating from and/or ending at users of the server. From here, file transfers can be administered and stats can be tracked.
    Alexander Wenckus
    • Method Detail

      • acceptIncomingFileTransferRequest

        boolean acceptIncomingFileTransferRequest​(FileTransfer transfer)
                                           throws FileTransferRejectedException
        Checks an incoming file transfer request to see if it should be accepted or rejected. If it is accepted true will be returned and if it is rejected false will be returned.
        transfer - the transfer to test for acceptance
        true if it should be accepted false if it should not.
        FileTransferRejectedException - if the request was rejected (can this ever happen?)
      • registerProxyTransfer

        void registerProxyTransfer​(String transferDigest,
                                   ProxyTransfer proxyTransfer)
                            throws UnauthorizedException
        Registers that a transfer has begun through the proxy connected to the server.
        transferDigest - the digest of the initiator + target + sessionID that uniquely identifies a file transfer
        proxyTransfer - the related proxy transfer.
        UnauthorizedException - when in the current server configuration this transfer should not be permitted.
      • addListener

        void addListener​(FileTransferEventListener eventListener)
        Registers an event listener that will be notified of file transfer related events.
        eventListener - an event listener (cannot be null).
      • removeListener

        void removeListener​(FileTransferEventListener eventListener)
        Unregisters an event listener from the list of event listeners that are notified of file transfer related events.
        eventListener - an event listener (cannot be null).
      • fireFileTransferCompleted

        void fireFileTransferCompleted​(String sid,
                                       boolean wasSuccessful)
        sid - The session id of the file transfer that is being intercepted (cannot be null).
        wasSuccessful - false when an exception was thrown during file transfer, otherwise true.