/// 获取存储桶自定义域名 public void GetBucketDomain() { //.cssg-snippet-body-start:[get-bucket-domain] try { string bucket = "examplebucket-1250000000"; //格式:BucketName-APPID GetBucketDomainRequest request = new GetBucketDomainRequest(bucket); //执行请求 GetBucketDomainResult result = cosXml.getBucketDomain(request); //请求成功 Console.WriteLine(result.domainConfiguration); } catch (COSXML.CosException.CosClientException clientEx) { //请求失败 Console.WriteLine("CosClientException: " + clientEx); } catch (COSXML.CosException.CosServerException serverEx) { //请求失败 Console.WriteLine("CosServerException: " + serverEx.GetInfo()); } //.cssg-snippet-body-end }
public void GetBucketDomainAsync(GetBucketDomainRequest request, OnSuccessCallback <CosResult> successCallback, OnFailedCallback failCallback) { Schedue(request, new Model.Bucket.GetBucketDomainResult(), successCallback, failCallback); }
public GetBucketDomainResult GetBucketDomain(GetBucketDomainRequest request) { return((Model.Bucket.GetBucketDomainResult)Excute(request, new Model.Bucket.GetBucketDomainResult())); }