|
|
@ -194,6 +194,16 @@ type CompleteMultipartUploadResponse struct { |
|
|
|
ETag string |
|
|
|
ETag string |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// PostResponse container for completed post upload response
|
|
|
|
|
|
|
|
type PostResponse struct { |
|
|
|
|
|
|
|
XMLName xml.Name `xml:"http://s3.amazonaws.com/doc/2006-03-01/ PostResponse" json:"-"` |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Location string |
|
|
|
|
|
|
|
Bucket string |
|
|
|
|
|
|
|
Key string |
|
|
|
|
|
|
|
ETag string |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// DeleteError structure.
|
|
|
|
// DeleteError structure.
|
|
|
|
type DeleteError struct { |
|
|
|
type DeleteError struct { |
|
|
|
Code string |
|
|
|
Code string |
|
|
@ -217,6 +227,11 @@ func getLocation(r *http.Request) string { |
|
|
|
return r.URL.Path |
|
|
|
return r.URL.Path |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// getObjectLocation gets the relative URL for an object
|
|
|
|
|
|
|
|
func getObjectLocation(bucketName string, key string) string { |
|
|
|
|
|
|
|
return "/" + bucketName + "/" + key |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// takes an array of Bucketmetadata information for serialization
|
|
|
|
// takes an array of Bucketmetadata information for serialization
|
|
|
|
// input:
|
|
|
|
// input:
|
|
|
|
// array of bucket metadata
|
|
|
|
// array of bucket metadata
|
|
|
|