using System; using System.Collections.Generic; using System.Text; using COSXML.Common; namespace COSXML.Model.Object { /// /// 检查对象是否存在, 封装了Head接口 /// /// public sealed class DoesObjectExistRequest : ObjectRequest { public DoesObjectExistRequest(string bucket, string key) : base(bucket, key) { this.method = CosRequestMethod.HEAD; } /// /// 特定版本的对象 /// /// public void SetVersionId(string versionId) { if (versionId != null) { SetQueryParameter(CosRequestHeaderKey.VERSION_ID, versionId); } } } }