123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354 |
-
- using System;
- using Aliyun.OSS.Common.Communication;
- using Aliyun.OSS.Util;
- using System.Collections.Generic;
- namespace Aliyun.OSS.Commands
- {
- internal class DeleteBucketCorsCommand : OssCommand
- {
- private readonly string _bucketName;
- protected override HttpMethod Method
- {
- get { return HttpMethod.Delete; }
- }
- protected override string Bucket
- {
- get { return _bucketName; }
- }
- private DeleteBucketCorsCommand(IServiceClient client, Uri endpoint, ExecutionContext context,
- string bucketName)
- : base(client, endpoint, context)
- {
- OssUtils.CheckBucketName(bucketName);
- _bucketName = bucketName;
- }
- public static DeleteBucketCorsCommand Create(IServiceClient client, Uri endpoint,
- ExecutionContext context,
- string bucketName)
- {
- return new DeleteBucketCorsCommand(client, endpoint, context, bucketName);
- }
- protected override IDictionary<string, string> Parameters
- {
- get
- {
- return new Dictionary<string, string>()
- {
- { RequestParameters.SUBRESOURCE_CORS, null }
- };
- }
- }
- }
- }
|