Package org.yamcs.cfdp
Class QueuedCfdpOutgoingTransfer
java.lang.Object
org.yamcs.cfdp.QueuedCfdpOutgoingTransfer
- All Implemented Interfaces:
CfdpFileTransfer
,FileTransfer
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.yamcs.cfdp.CfdpFileTransfer
CfdpFileTransfer.PredefinedTransferTypes
-
Constructor Summary
ConstructorsConstructorDescriptionQueuedCfdpOutgoingTransfer
(long initiatorEntityId, long id, long creationTime, PutRequest putRequest, Bucket bucket, Integer customPduSize, Integer customPduDelay) -
Method Summary
Modifier and TypeMethodDescriptionboolean
return the name of the bucket where the file is being transfered to/from.long
long
long
getId()
long
return the name of the object (file) which is being transfered.return the remote path of the file which is being transfered.long
long
return the file size in bytes or -1 if the size is not known.Get the CFDP transaction id.long
boolean
boolean
pausable()
void
setFailureReason
(String failureReason) void
setTransferState
(TransferState state)
-
Constructor Details
-
QueuedCfdpOutgoingTransfer
public QueuedCfdpOutgoingTransfer(long initiatorEntityId, long id, long creationTime, PutRequest putRequest, Bucket bucket, Integer customPduSize, Integer customPduDelay)
-
-
Method Details
-
getBucketName
Description copied from interface:FileTransfer
return the name of the bucket where the file is being transfered to/from.Could be null for incoming transfers. For the CFDP service, the bucket is determined by the source or destination entity id and it is not null. However if the bucket was determined by the filename which is known only when the metadata packet is received, this could be null.
- Specified by:
getBucketName
in interfaceFileTransfer
-
getObjectName
Description copied from interface:FileTransfer
return the name of the object (file) which is being transfered. This is the filename on the local (Yamcs) site.Can be null for incoming transfers - for example CFDP can start a transfer without knowing the filename if the first metadata packet has been lost.
- Specified by:
getObjectName
in interfaceFileTransfer
-
getRemotePath
Description copied from interface:FileTransfer
return the remote path of the file which is being transfered.Can be null for incoming transfers - for example CFDP can start a transfer without having this information if the first metadata packet has been lost.
- Specified by:
getRemotePath
in interfaceFileTransfer
-
getDirection
- Specified by:
getDirection
in interfaceFileTransfer
-
getTotalSize
public long getTotalSize()Description copied from interface:FileTransfer
return the file size in bytes or -1 if the size is not known.For the CFDP service the incoming files can be unbounded (but this is not yet supported) or the size will be part of the metadata packet which may be missing.
- Specified by:
getTotalSize
in interfaceFileTransfer
-
getTransferredSize
public long getTransferredSize()- Specified by:
getTransferredSize
in interfaceFileTransfer
-
getId
public long getId()- Specified by:
getId
in interfaceFileTransfer
-
getTransferState
- Specified by:
getTransferState
in interfaceFileTransfer
-
isReliable
public boolean isReliable()- Specified by:
isReliable
in interfaceFileTransfer
-
getFailuredReason
- Specified by:
getFailuredReason
in interfaceFileTransfer
-
getStartTime
public long getStartTime()- Specified by:
getStartTime
in interfaceFileTransfer
-
pausable
public boolean pausable()- Specified by:
pausable
in interfaceFileTransfer
-
cancellable
public boolean cancellable()- Specified by:
cancellable
in interfaceFileTransfer
-
getTransactionId
Description copied from interface:CfdpFileTransfer
Get the CFDP transaction id. Returns null for queued transfers.- Specified by:
getTransactionId
in interfaceCfdpFileTransfer
- Returns:
-
getDestinationId
public long getDestinationId()- Specified by:
getDestinationId
in interfaceCfdpFileTransfer
-
getTransferType
- Specified by:
getTransferType
in interfaceFileTransfer
-
setTransferState
-
setFailureReason
-
getCreationTime
public long getCreationTime()- Specified by:
getCreationTime
in interfaceFileTransfer
-
getInitiatorEntityId
public long getInitiatorEntityId()- Specified by:
getInitiatorEntityId
in interfaceCfdpFileTransfer
-
getPutRequest
-
getBucket
-
getCustomPduSize
-
getCustomPduDelay
-