// error code to APIError structure, these fields carry respective
// descriptions for all the error responses.
varerrorCodeResponse=map[ErrorCode]APIError{
ErrMethodNotAllowed:{
Code:"MethodNotAllowed",
Description:"The specified method is not allowed against this resource.",
HTTPStatusCode:http.StatusMethodNotAllowed,
},
ErrBucketNotEmpty:{
Code:"BucketNotEmpty",
Description:"The bucket you tried to delete is not empty",
HTTPStatusCode:http.StatusConflict,
},
ErrBucketAlreadyExists:{
Code:"BucketAlreadyExists",
Description:"The requested bucket name is not available. The bucket namespace is shared by all users of the system. Please select a different name and try again.",
HTTPStatusCode:http.StatusConflict,
},
ErrBucketAlreadyOwnedByYou:{
Code:"BucketAlreadyOwnedByYou",
Description:"Your previous request to create the named bucket succeeded and you already own it.",