org.apache.oodt.cas.filemgr.structs
Class FileTransferStatus

java.lang.Object
  extended by org.apache.oodt.cas.filemgr.structs.FileTransferStatus

public class FileTransferStatus
extends Object

Version:
$Revision: 11462 $

A class to represent the status of a transfer for a file reference belonging to a Product.

Author:
mattmann

Constructor Summary
FileTransferStatus()
           Default Constructor
FileTransferStatus(Reference fileRef, long fileSize, long bytesTransferred, Product parentProduct)
           
 
Method Summary
 double computePctTransferred()
           
 long getBytesTransferred()
           
 Reference getFileRef()
           
 Product getParentProduct()
           
 void setBytesTransferred(long bytesTransferred)
           
 void setFileRef(Reference fileRef)
           
 void setParentProduct(Product parentProduct)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FileTransferStatus

public FileTransferStatus()

Default Constructor

.


FileTransferStatus

public FileTransferStatus(Reference fileRef,
                          long fileSize,
                          long bytesTransferred,
                          Product parentProduct)
Parameters:
fileRef - The file reference being transferred.
bytesTransferred - The number of bytes transferred so far for this file.
parentProduct - The parent Product that this file reference belongs to.
Method Detail

getBytesTransferred

public long getBytesTransferred()
Returns:
Returns the bytesTransferred.

setBytesTransferred

public void setBytesTransferred(long bytesTransferred)
Parameters:
bytesTransferred - The bytesTransferred to set.

getFileRef

public Reference getFileRef()
Returns:
Returns the fileRef.

setFileRef

public void setFileRef(Reference fileRef)
Parameters:
fileRef - The fileRef to set.

getParentProduct

public Product getParentProduct()
Returns:
Returns the parentProduct.

setParentProduct

public void setParentProduct(Product parentProduct)
Parameters:
parentProduct - The parentProduct to set.

computePctTransferred

public double computePctTransferred()
Returns:
The percentage of the file that has been transferred so far.


Copyright © 1999-2011 Apache OODT. All Rights Reserved.