CopyPart Method
Copy the specified object as a part of a multipart upload.
Syntax
amazons3.copyPart(srcObjectName, destBucket, destObjectName, destPartNumber, destUploadId, [callback])
Callback
The 'callback' parameter specifies a function which will be called when the operation completes (or an error is encountered). If the 'callback' parameter is not specified, then the method will block and will not return until the operation completes (or an error is encountered).
The callback for this method is defined as:
function(err){ }
'err' is the error that occurred. If there was no error, then 'err' is 'null'.
'err' has 2 properties which hold detailed information:
err.code err.message
Remarks
This method allows you to copy an existing object as a part in a multipart upload. After a multipart upload has been started with StartMultipartUpload this method may be used to copy an existing object into a part of the multipart upload.
The source object is specified by setting Bucket and the SrcObjectName parameter. The DestBucket and DestObjectName parameters define the destination location. The DestPartNumber, and DestUploadId define the existing multipart upload to which the part is being copied.
You may optionally define a range of bytes to copy from the source object. See CopyPartRange for more details.