src/advance.js
function wholeMultipartListPart(params, callback) {
    var self = this;
    var PartList = [];
    var sendParams = {
        Bucket: params.Bucket,
        Region: params.Region,
        Key: params.Key,
        UploadId: params.UploadId
    };
    var next = function () {
        self.multipartListPart(sendParams, function (err, data) {
            if (err) return callback(err);
            PartList.push.apply(PartList, data.Part || []);
            if (data.IsTruncated === 'true') { // 列表不完整
                sendParams.PartNumberMarker = data.NextPartNumberMarker;
                next();
            } else {
                callback(null, {PartList: PartList});
            }
        });
    };
    next();
}
function wholeMultipartListPart(params, callback) {
    var self = this;
    var PartList = [];
    var sendParams = {
        Bucket: params.Bucket,
        Region: params.Region,
        Key: params.Key,
        UploadId: params.UploadId
    };
    var next = function () {
        self.multipartListPart(sendParams, function (err, data) {
            if (err) return callback(err);
            PartList.push.apply(PartList, data.Part || []);
            if (data.IsTruncated === 'true') { // 列表不完整
                sendParams.PartNumberMarker = data.NextPartNumberMarker;
                next();
            } else {
                callback(null, {PartList: PartList});
            }
        });
    };
    next();
}
function wholeMultipartListPart ( params , callback ) { var self = this ; var PartList = [ ] ; var sendParams = { Bucket : params . Bucket , Region : params . Region , Key : params . Key , UploadId : params . UploadId } ; var next = function ( ) { self . multipartListPart ( sendParams , function ( err , data ) { if ( err ) return callback ( err ) ; PartList . push . apply ( PartList , data . Part || [ ] ) ; if ( data . IsTruncated === 'true' ) { // 列表不完整 sendParams . PartNumberMarker = data . NextPartNumberMarker ; next ( ) ; } else { callback ( null , { PartList : PartList } ) ; } } ) ; } ; next ( ) ; }
获取指定上传任务的分块列表
获取指定上传任务的分块列表