Jitsi: the OpenSource Java VoIP and Instant Messaging client.

net.java.sip.communicator.impl.protocol.ssh
Class FileTransferSSHImpl

java.lang.Object
  extended by net.java.sip.communicator.service.protocol.AbstractFileTransfer
      extended by net.java.sip.communicator.impl.protocol.ssh.FileTransferSSHImpl
All Implemented Interfaces:
FileTransfer

public class FileTransferSSHImpl
extends AbstractFileTransfer

SSH implementation of the AbstractFileTransfer.

Author:
Yana Stamcheva

Field Summary
 
Fields inherited from interface net.java.sip.communicator.service.protocol.FileTransfer
IN, OUT
 
Constructor Summary
FileTransferSSHImpl(SSHFileTransferDaemon fileTransfer, Date date)
          Creates an SSH implementation of the file transfer interface.
 
Method Summary
 void cancel()
          Cancels this file transfer.
 Contact getContact()
          Returns the contact that we are transfering files with.
 int getDirection()
          The file transfer direction.
 String getID()
          Uniquie ID that is identifying the FileTransfer if the request has been accepted.
 Date getInitialDate()
           
 File getLocalFile()
          Returns the local file that is being transferred or to which we transfer.
 long getTransferedBytes()
          Returns the number of bytes already transfered through this file transfer.
 
Methods inherited from class net.java.sip.communicator.service.protocol.AbstractFileTransfer
addProgressListener, addStatusListener, fireProgressChangeEvent, fireStatusChangeEvent, fireStatusChangeEvent, getStatus, removeProgressListener, removeStatusListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FileTransferSSHImpl

public FileTransferSSHImpl(SSHFileTransferDaemon fileTransfer,
                           Date date)
Creates an SSH implementation of the file transfer interface.

Parameters:
fileTransfer - the SSH file transfer
date - the initial date of the transfer
Method Detail

cancel

public void cancel()
Cancels this file transfer. When this method is called transfer should be interrupted.

Specified by:
cancel in interface FileTransfer
Specified by:
cancel in class AbstractFileTransfer

getTransferedBytes

public long getTransferedBytes()
Returns the number of bytes already transfered through this file transfer.

Specified by:
getTransferedBytes in interface FileTransfer
Specified by:
getTransferedBytes in class AbstractFileTransfer
Returns:
the number of bytes already transfered through this file transfer

getDirection

public int getDirection()
Description copied from interface: FileTransfer
The file transfer direction.

Returns:
returns the direction of the file transfer : IN or OUT.

getLocalFile

public File getLocalFile()
Description copied from interface: FileTransfer
Returns the local file that is being transferred or to which we transfer.

Returns:
the file

getContact

public Contact getContact()
Description copied from interface: FileTransfer
Returns the contact that we are transfering files with.

Returns:
the contact.

getID

public String getID()
Description copied from interface: FileTransfer
Uniquie ID that is identifying the FileTransfer if the request has been accepted.

Returns:
the id.

getInitialDate

public Date getInitialDate()

Jitsi: the OpenSource Java VoIP and Instant Messaging client.

Jitsi, the OpenSource Java VoIP and Instant Messaging client.
Distributable under LGPL license.