CosXml.cs 54 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Text;
  4. using COSXML.Model.Service;
  5. using COSXML.Model.Bucket;
  6. using COSXML.Model.Object;
  7. using COSXML.Model.CI;
  8. using COSXML.Model;
  9. using COSXML.Model.Tag;
  10. #if !COMPATIBLE
  11. using System.Threading.Tasks;
  12. #endif
  13. namespace COSXML
  14. {
  15. /// <summary>
  16. /// COS 接口类,实现 COS XML 的所有功能。
  17. /// </summary>
  18. public interface CosXml
  19. {
  20. /// <summary>
  21. /// 获取配置项
  22. /// </summary>
  23. /// <returns></returns>
  24. CosXmlConfig GetConfig();
  25. /// <summary>
  26. /// 生成签名串
  27. /// </summary>
  28. /// <param name="method">http method</param>
  29. /// <param name="key">http url path</param>
  30. /// <param name="queryParameters">http url query</param>
  31. /// <param name="headers">http header</param>
  32. /// <param name="signDurationSecond">sign time</param>
  33. /// <returns></returns>
  34. string GenerateSign(string method, string key, Dictionary<string, string> queryParameters,
  35. Dictionary<string, string> headers, long signDurationSecond, long keyDurationSecond);
  36. /// <summary>
  37. /// 生成预签名URL
  38. /// </summary>
  39. /// <param name="preSignatureStruct">签名结构体</param>
  40. /// <returns></returns>
  41. string GenerateSignURL(PreSignatureStruct preSignatureStruct);
  42. /// <summary>
  43. /// 获取存储桶列表
  44. /// </summary>
  45. /// <param name="request"> <see href="COSXML.Model.Service.GetServiceRequest"/>GetServiceRequest </param>
  46. /// <returns><see href="COSXML.Model.Service.GetServiceResult"/>GetServiceResult</returns>
  47. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  48. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  49. GetServiceResult GetService(GetServiceRequest request);
  50. /// <summary>
  51. /// 获取存储桶列表的异步方法
  52. /// </summary>
  53. /// <param name="request">GetServiceRequest</param>
  54. /// <param name="successCallback">OnSuccessCallback</param>
  55. /// <param name="failCallback">OnFailedCallback</param>
  56. void GetService(GetServiceRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  57. /// <summary>
  58. /// 创建存储桶
  59. /// </summary>
  60. /// <param name="request">PutBucketRequest</param>
  61. /// <returns>PutBucketResult</returns>
  62. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  63. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  64. PutBucketResult PutBucket(PutBucketRequest request);
  65. /// <summary>
  66. /// 创建存储桶的异步方法
  67. /// </summary>
  68. /// <param name="request"></param>
  69. /// <param name="successCallback"></param>
  70. /// <param name="failCallback"></param>
  71. void PutBucket(PutBucketRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  72. /// <summary>
  73. /// 检索存储桶
  74. /// </summary>
  75. /// <param name="request">HeadBucketRequest</param>
  76. /// <returns>HeadBucketResult</returns>
  77. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  78. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  79. HeadBucketResult HeadBucket(HeadBucketRequest request);
  80. /// <summary>
  81. /// 检索存储桶的异步方法
  82. /// </summary>
  83. /// <param name="request"></param>
  84. /// <param name="successCallback"></param>
  85. /// <param name="failCallback"></param>
  86. void HeadBucket(HeadBucketRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  87. /// <summary>
  88. /// 检查存储桶是否存在(只有同步方法)
  89. /// </summary>
  90. /// <param name="request"></param>
  91. /// <param name="successCallback"></param>
  92. /// <param name="failCallback"></param>
  93. bool DoesBucketExist(DoesBucketExistRequest request);
  94. /// <summary>
  95. /// 列出存储桶下的文件
  96. /// </summary>
  97. /// <param name="request">GetBucketRequest</param>
  98. /// <returns>GetBucketResult</returns>
  99. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  100. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  101. GetBucketResult GetBucket(GetBucketRequest request);
  102. /// <summary>
  103. /// 列出存储桶下文件的异步方法
  104. /// </summary>
  105. /// <param name="request"></param>
  106. /// <param name="successCallback"></param>
  107. /// <param name="failCallback"></param>
  108. void GetBucket(GetBucketRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  109. /// <summary>
  110. /// 删除存储桶
  111. /// </summary>
  112. /// <param name="request">DeleteBucketRequest</param>
  113. /// <returns>DeleteBucketResult</returns>
  114. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  115. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  116. DeleteBucketResult DeleteBucket(DeleteBucketRequest request);
  117. /// <summary>
  118. /// 删除存储桶的异步方法
  119. /// </summary>
  120. /// <param name="request"></param>
  121. /// <param name="successCallback"></param>
  122. /// <param name="failCallback"></param>
  123. void DeleteBucket(DeleteBucketRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  124. /// <summary>
  125. /// 设置存储桶权限
  126. /// </summary>
  127. /// <param name="request">PutBucketACLRequest</param>
  128. /// <returns>PutBucketACLResult</returns>
  129. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  130. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  131. PutBucketACLResult PutBucketACL(PutBucketACLRequest request);
  132. /// <summary>
  133. /// 设置存储桶权限的异步方法
  134. /// </summary>
  135. /// <param name="request"></param>
  136. /// <param name="successCallback"></param>
  137. /// <param name="failCallback"></param>
  138. void PutBucketACL(PutBucketACLRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  139. /// <summary>
  140. /// 查询存储桶权限
  141. /// </summary>
  142. /// <param name="request">GetBucketACLRequest</param>
  143. /// <returns>GetBucketACLResult</returns>
  144. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  145. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  146. GetBucketACLResult GetBucketACL(GetBucketACLRequest request);
  147. /// <summary>
  148. /// 查询存储桶权限的异步方法
  149. /// </summary>
  150. /// <param name="request"></param>
  151. /// <param name="successCallback"></param>
  152. /// <param name="failCallback"></param>
  153. void GetBucketACL(GetBucketACLRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  154. /// <summary>
  155. /// 设置存储桶的跨域规则
  156. /// </summary>
  157. /// <param name="request">PutBucketCORSRequest</param>
  158. /// <returns>PutBucketCORSResult</returns>
  159. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  160. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  161. PutBucketCORSResult PutBucketCORS(PutBucketCORSRequest request);
  162. /// <summary>
  163. /// 设置存储桶跨域规则的异步方法
  164. /// </summary>
  165. /// <param name="request"></param>
  166. /// <param name="successCallback"></param>
  167. /// <param name="failCallback"></param>
  168. void PutBucketCORS(PutBucketCORSRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  169. /// <summary>
  170. /// 获取存储桶跨域规则
  171. /// </summary>
  172. /// <param name="request">GetBucketCORSRequest</param>
  173. /// <returns>GetBucketCORSResult</returns>
  174. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  175. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  176. GetBucketCORSResult GetBucketCORS(GetBucketCORSRequest request);
  177. /// <summary>
  178. /// 获取存储桶跨域规则的异步方法
  179. /// </summary>
  180. /// <param name="request"></param>
  181. /// <param name="successCallback"></param>
  182. /// <param name="failCallback"></param>
  183. void GetBucketCORS(GetBucketCORSRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  184. /// <summary>
  185. /// 删除存储桶跨域规则
  186. /// </summary>
  187. /// <param name="request">DeleteBucketCORSRequest</param>
  188. /// <returns>DeleteBucketCORSResult</returns>
  189. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  190. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  191. DeleteBucketCORSResult DeleteBucketCORS(DeleteBucketCORSRequest request);
  192. /// <summary>
  193. /// 删除存储桶跨域规则的异步方法
  194. /// </summary>
  195. /// <param name="request"></param>
  196. /// <param name="successCallback"></param>
  197. /// <param name="failCallback"></param>
  198. void DeleteBucketCORS(DeleteBucketCORSRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  199. /// <summary>
  200. /// 设置存储桶生命周期
  201. /// </summary>
  202. /// <param name="request">PutBucketLifecycleRequest</param>
  203. /// <returns>PutBucketLifecycleResult</returns>
  204. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  205. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  206. PutBucketLifecycleResult PutBucketLifecycle(PutBucketLifecycleRequest request);
  207. /// <summary>
  208. /// 设置存储桶生命周期的异步方法
  209. /// </summary>
  210. /// <param name="request"></param>
  211. /// <param name="successCallback"></param>
  212. /// <param name="failCallback"></param>
  213. void PutBucketLifecycle(PutBucketLifecycleRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  214. /// <summary>
  215. /// 获取存储桶生命周期规则
  216. /// </summary>
  217. /// <param name="request">GetBucketLifecycleRequest</param>
  218. /// <returns>GetBucketLifecycleResult</returns>
  219. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  220. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  221. GetBucketLifecycleResult GetBucketLifecycle(GetBucketLifecycleRequest request);
  222. /// <summary>
  223. /// 获取存储桶生命周期规则的异步方法
  224. /// </summary>
  225. /// <param name="request"></param>
  226. /// <param name="successCallback"></param>
  227. /// <param name="failCallback"></param>
  228. void GetBucketLifecycle(GetBucketLifecycleRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  229. /// <summary>
  230. /// 删除存储桶生命周期规则
  231. /// </summary>
  232. /// <param name="request">DeleteBucketLifecycleRequest</param>
  233. /// <returns>DeleteBucketLifecycleResult</returns>
  234. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  235. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  236. DeleteBucketLifecycleResult DeleteBucketLifecycle(DeleteBucketLifecycleRequest request);
  237. /// <summary>
  238. /// 删除存储桶生命周期规则的异步方法
  239. /// </summary>
  240. /// <param name="request"></param>
  241. /// <param name="successCallback"></param>
  242. /// <param name="failCallback"></param>
  243. void DeleteBucketLifecycle(DeleteBucketLifecycleRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  244. /// <summary>
  245. /// 设置存储桶跨地域复制规则
  246. /// </summary>
  247. /// <param name="request">PutBucketReplicationRequest</param>
  248. /// <returns>PutBucketReplicationResult</returns>
  249. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  250. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  251. PutBucketReplicationResult PutBucketReplication(PutBucketReplicationRequest request);
  252. /// <summary>
  253. /// 设置存储桶跨地域复制规则的异步方法
  254. /// </summary>
  255. /// <param name="request"></param>
  256. /// <param name="successCallback"></param>
  257. /// <param name="failCallback"></param>
  258. void PutBucketReplication(PutBucketReplicationRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  259. /// <summary>
  260. /// 获取存储桶跨地域复制规则
  261. /// </summary>
  262. /// <param name="request">GetBucketReplicationRequest</param>
  263. /// <returns>GetBucketReplicationResult</returns>
  264. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  265. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  266. GetBucketReplicationResult GetBucketReplication(GetBucketReplicationRequest request);
  267. /// <summary>
  268. /// 获取存储桶跨地域复制规则的异步方法
  269. /// </summary>
  270. /// <param name="request"></param>
  271. /// <param name="successCallback"></param>
  272. /// <param name="failCallback"></param>
  273. void GetBucketReplication(GetBucketReplicationRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  274. /// <summary>
  275. /// 删除存储桶跨地域复制规则
  276. /// </summary>
  277. /// <param name="request">DeleteBucketReplicationRequest</param>
  278. /// <returns>DeleteBucketReplicationResult</returns>
  279. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  280. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  281. DeleteBucketReplicationResult DeleteBucketReplication(DeleteBucketReplicationRequest request);
  282. /// <summary>
  283. /// 删除存储桶跨地域复制规则的异步方法
  284. /// </summary>
  285. /// <param name="request"></param>
  286. /// <param name="successCallback"></param>
  287. /// <param name="failCallback"></param>
  288. void DeleteBucketReplication(DeleteBucketReplicationRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  289. /// <summary>
  290. /// 设置存储桶多版本状态
  291. /// </summary>
  292. /// <param name="request">PutBucketVersioningRequest</param>
  293. /// <returns>PutBucketVersioningResult</returns>
  294. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  295. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  296. PutBucketVersioningResult PutBucketVersioning(PutBucketVersioningRequest request);
  297. /// <summary>
  298. /// 设置存储桶多版本状态的异步方法
  299. /// </summary>
  300. /// <param name="request"></param>
  301. /// <param name="successCallback"></param>
  302. /// <param name="failCallback"></param>
  303. void PutBucketVersioning(PutBucketVersioningRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  304. /// <summary>
  305. /// 获取存储桶多版本状态
  306. /// </summary>
  307. /// <param name="request">GetBucketVersioningRequest</param>
  308. /// <returns>GetBucketVersioningResult</returns>
  309. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  310. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  311. GetBucketVersioningResult GetBucketVersioning(GetBucketVersioningRequest request);
  312. /// <summary>
  313. /// 获取存储桶多版本状态的异步方法
  314. /// </summary>
  315. /// <param name="request"></param>
  316. /// <param name="successCallback"></param>
  317. /// <param name="failCallback"></param>
  318. void GetBucketVersioning(GetBucketVersioningRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  319. /// <summary>
  320. /// 设置存储桶防盗链
  321. /// </summary>
  322. /// <param name="request">PutBucketRefererRequest</param>
  323. /// <returns>PutBucketRefererResult</returns>
  324. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  325. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  326. PutBucketRefererResult PutBucketReferer(PutBucketRefererRequest request);
  327. /// <summary>
  328. /// 设置存储桶防盗链的异步方法
  329. /// </summary>
  330. /// <param name="request"></param>
  331. /// <param name="successCallback"></param>
  332. /// <param name="failCallback"></param>
  333. void PutBucketReferer(PutBucketRefererRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  334. /// <summary>
  335. /// 获取存储桶防盗链
  336. /// </summary>
  337. /// <param name="request">GetBucketRefererRequest</param>
  338. /// <returns>GetBucketRefererResult</returns>
  339. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  340. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  341. GetBucketRefererResult GetBucketReferer(GetBucketRefererRequest request);
  342. /// <summary>
  343. /// 获取存储桶防盗链的异步方法
  344. /// </summary>
  345. /// <param name="request"></param>
  346. /// <param name="successCallback"></param>
  347. /// <param name="failCallback"></param>
  348. void GetBucketReferer(GetBucketRefererRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  349. /// <summary>
  350. /// 列出多版本对象列表
  351. /// </summary>
  352. /// <param name="request">ListBucketVersionsRequest</param>
  353. /// <returns>ListBucketVersionsResult</returns>
  354. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  355. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  356. ListBucketVersionsResult ListBucketVersions(ListBucketVersionsRequest request);
  357. /// <summary>
  358. /// 列出多版本对象列表的异步方法
  359. /// </summary>
  360. /// <param name="request">ListBucketVersionsRequest</param>
  361. /// <param name="successCallback">successCallback</param>
  362. /// <param name="failCallback">failCallback</param>
  363. void ListBucketVersions(ListBucketVersionsRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  364. /// <summary>
  365. /// 列出所有未完成的分片上传任务
  366. /// </summary>
  367. /// <param name="request">ListMultiUploadsRequest</param>
  368. /// <returns>ListMultiUploadsResult</returns>
  369. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  370. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  371. ListMultiUploadsResult ListMultiUploads(ListMultiUploadsRequest request);
  372. /// <summary>
  373. /// 列出所有未完成的分片上传任务的异步方法
  374. /// </summary>
  375. /// <param name="request"></param>
  376. /// <param name="successCallback"></param>
  377. /// <param name="failCallback"></param>
  378. void ListMultiUploads(ListMultiUploadsRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  379. /// <summary>
  380. /// 简单上传对象
  381. /// </summary>
  382. /// <param name="request">PutObjectRequest</param>
  383. /// <returns>PutObjectResult</returns>
  384. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  385. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  386. PutObjectResult PutObject(PutObjectRequest request);
  387. /// <summary>
  388. /// 简单上传对象的异步方法
  389. /// </summary>
  390. /// <param name="request"></param>
  391. /// <param name="successCallback"></param>
  392. /// <param name="failCallback"></param>
  393. void PutObject(PutObjectRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  394. /// <summary>
  395. /// 检索对象属性
  396. /// </summary>
  397. /// <param name="request">HeadObjectRequest</param>
  398. /// <returns>HeadObjectResult</returns>
  399. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  400. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  401. HeadObjectResult HeadObject(HeadObjectRequest request);
  402. /// <summary>
  403. /// 检索对象属性的异步方法
  404. /// </summary>
  405. /// <param name="request"></param>
  406. /// <param name="successCallback"></param>
  407. /// <param name="failCallback"></param>
  408. void HeadObject(HeadObjectRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  409. /// <summary>
  410. /// 检查对象是否存在(只支持同步方法)
  411. /// </summary>
  412. /// <param name="request"></param>
  413. /// <param name="successCallback"></param>
  414. /// <param name="failCallback"></param>
  415. bool DoesObjectExist(DoesObjectExistRequest request);
  416. /// <summary>
  417. /// 下载对象
  418. /// </summary>
  419. /// <param name="request">GetObjectRequest</param>
  420. /// <returns>GetObjectResult</returns>
  421. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  422. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  423. GetObjectResult GetObject(GetObjectRequest request);
  424. /// <summary>
  425. /// 下载对象的异步方法
  426. /// </summary>
  427. /// <param name="request"></param>
  428. /// <param name="successCallback"></param>
  429. /// <param name="failCallback"></param>
  430. void GetObject(GetObjectRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  431. /// <summary>
  432. /// 下载对象到内存中
  433. /// </summary>
  434. /// <param name="request"></param>
  435. /// <returns>GetObjectBytesResult</returns>
  436. GetObjectBytesResult GetObject(GetObjectBytesRequest request);
  437. /// <summary>
  438. /// 下载对象到内存中的异步方法
  439. /// </summary>
  440. /// <param name="request"></param>
  441. /// <param name="successCallback"></param>
  442. /// <param name="failCallback"></param>
  443. void GetObject(GetObjectBytesRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  444. /// <summary>
  445. /// 获取对象访问URL
  446. /// </summary>
  447. /// <param name="bucket">bucket</param>
  448. /// <param name="key">object key</param>
  449. /// <returns></returns>
  450. string GetObjectUrl(string bucket, string key);
  451. /// <summary>
  452. /// 设置对象 ACL 权限
  453. /// </summary>
  454. /// <param name="request">PutObjectACLRequest</param>
  455. /// <returns>PutObjectACLResult</returns>
  456. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  457. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  458. PutObjectACLResult PutObjectACL(PutObjectACLRequest request);
  459. /// <summary>
  460. /// 设置对象 ACL 权限的异步方法
  461. /// </summary>
  462. /// <param name="request"></param>
  463. /// <param name="successCallback"></param>
  464. /// <param name="failCallback"></param>
  465. void PutObjectACL(PutObjectACLRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  466. /// <summary>
  467. /// Append上传对象
  468. /// </summary>
  469. /// <param name="request"></param>
  470. AppendObjectResult AppendObject(AppendObjectRequest request);
  471. /// <summary>
  472. /// 获取对象 ACL 权限
  473. /// </summary>
  474. /// <param name="request">GetObjectACLRequest</param>
  475. /// <returns>GetObjectACLResult</returns>
  476. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  477. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  478. GetObjectACLResult GetObjectACL(GetObjectACLRequest request);
  479. /// <summary>
  480. /// 获取对象 ACL 权限的异步方法
  481. /// </summary>
  482. /// <param name="request"></param>
  483. /// <param name="successCallback"></param>
  484. /// <param name="failCallback"></param>
  485. void GetObjectACL(GetObjectACLRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  486. /// <summary>
  487. /// 设置对象标签的同步方法
  488. /// </summary>
  489. /// <param name="request"></param>
  490. PutObjectTaggingResult PutObjectTagging(PutObjectTaggingRequest request);
  491. /// <summary>
  492. /// 设置对象标签的异步方法
  493. /// </summary>
  494. /// <param name="request"></param>
  495. /// <param name="successCallback"></param>
  496. /// <param name="failCallback"></param>
  497. void PutObjectTagging(PutObjectTaggingRequest request, Callback.OnSuccessCallback<CosResult> successCallback, Callback.OnFailedCallback failCallback);
  498. /// <summary>
  499. /// 获取对象标签的同步方法
  500. /// </summary>
  501. /// <param name="request"></param>
  502. GetObjectTaggingResult GetObjectTagging(GetObjectTaggingRequest request);
  503. /// <summary>
  504. /// 获取对象标签的异步方法
  505. /// </summary>
  506. /// <param name="request"></param>
  507. /// <param name="successCallback"></param>
  508. /// <param name="failCallback"></param>
  509. void GetObjectTagging(GetObjectTaggingRequest request, Callback.OnSuccessCallback<CosResult> successCallback, Callback.OnFailedCallback failCallback);
  510. /// <summary>
  511. /// 删除对象标签的同步方法
  512. /// </summary>
  513. /// <param name="request"></param>
  514. DeleteObjectTaggingResult DeleteObjectTagging(DeleteObjectTaggingRequest request);
  515. /// <summary>
  516. /// 删除对象标签的异步方法
  517. /// </summary>
  518. /// <param name="request"></param>
  519. /// <param name="successCallback"></param>
  520. /// <param name="failCallback"></param>
  521. void DeleteObjectTagging(DeleteObjectTaggingRequest request, Callback.OnSuccessCallback<CosResult> successCallback, Callback.OnFailedCallback failCallback);
  522. /// <summary>
  523. /// 删除对象
  524. /// </summary>
  525. /// <param name="request">DeleteObjectRequest</param>
  526. /// <returns>DeleteObjectResult</returns>
  527. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  528. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  529. DeleteObjectResult DeleteObject(DeleteObjectRequest request);
  530. /// <summary>
  531. /// 删除对象的异步方法
  532. /// </summary>
  533. /// <param name="request"></param>
  534. /// <param name="successCallback"></param>
  535. /// <param name="failCallback"></param>
  536. void DeleteObject(DeleteObjectRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  537. /// <summary>
  538. /// 批量删除对象
  539. /// </summary>
  540. /// <param name="request">DeleteMultiObjectRequest</param>
  541. /// <returns>DeleteMultiObjectResult</returns>
  542. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  543. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  544. DeleteMultiObjectResult DeleteMultiObjects(DeleteMultiObjectRequest request);
  545. /// <summary>
  546. /// 批量删除对象的异步方法
  547. /// </summary>
  548. /// <param name="request"></param>
  549. /// <param name="successCallback"></param>
  550. /// <param name="failCallback"></param>
  551. void DeleteMultiObjects(DeleteMultiObjectRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  552. /// <summary>
  553. /// 初始化分片上传任务
  554. /// </summary>
  555. /// <param name="request"></param>
  556. /// <returns></returns>
  557. InitMultipartUploadResult InitMultipartUpload(InitMultipartUploadRequest request);
  558. /// <summary>
  559. /// 初始化分片上传任务的异步方法
  560. /// </summary>
  561. /// <param name="request"></param>
  562. /// <param name="successCallback"></param>
  563. /// <param name="failCallback"></param>
  564. void InitMultipartUpload(InitMultipartUploadRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  565. /// <summary>
  566. /// 列出已上传的分片
  567. /// </summary>
  568. /// <param name="request">ListPartsRequest</param>
  569. /// <returns>ListPartsResult</returns>
  570. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  571. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  572. ListPartsResult ListParts(ListPartsRequest request);
  573. /// <summary>
  574. /// 列出已上传的分片的异步方法
  575. /// </summary>
  576. /// <param name="request"></param>
  577. /// <param name="successCallback"></param>
  578. /// <param name="failCallback"></param>
  579. void ListParts(ListPartsRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  580. /// <summary>
  581. /// 上传分片
  582. /// </summary>
  583. /// <param name="request">UploadPartRequest</param>
  584. /// <returns>UploadPartResult</returns>
  585. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  586. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  587. UploadPartResult UploadPart(UploadPartRequest request);
  588. /// <summary>
  589. /// 上传分片的异步方法
  590. /// </summary>
  591. /// <param name="request"></param>
  592. /// <param name="successCallback"></param>
  593. /// <param name="failCallback"></param>
  594. void UploadPart(UploadPartRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  595. /// <summary>
  596. /// 完成分片上传
  597. /// </summary>
  598. /// <param name="request">CompleteMultiUploadRequest</param>
  599. /// <returns>CompleteMultiUploadResult</returns>
  600. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  601. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  602. CompleteMultipartUploadResult CompleteMultiUpload(CompleteMultipartUploadRequest request);
  603. /// <summary>
  604. /// 完成分片上传的异步方法
  605. /// </summary>
  606. /// <param name="request"></param>
  607. /// <param name="successCallback"></param>
  608. /// <param name="failCallback"></param>
  609. void CompleteMultiUpload(CompleteMultipartUploadRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  610. /// <summary>
  611. /// 终止分片上传
  612. /// </summary>
  613. /// <param name="request">AbortMultiUploadRequest</param>
  614. /// <returns>AbortMultiUploadResult</returns>
  615. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  616. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  617. AbortMultipartUploadResult AbortMultiUpload(AbortMultipartUploadRequest request);
  618. /// <summary>
  619. /// 终止分片上传的异步方法
  620. /// </summary>
  621. /// <param name="request"></param>
  622. /// <param name="successCallback"></param>
  623. /// <param name="failCallback"></param>
  624. void AbortMultiUpload(AbortMultipartUploadRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  625. /// <summary>
  626. /// 复制对象
  627. /// </summary>
  628. /// <param name="request">CopyObjectRequest</param>
  629. /// <returns>CopyObjectResult</returns>
  630. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  631. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  632. CopyObjectResult CopyObject(CopyObjectRequest request);
  633. /// <summary>
  634. /// 复制对象的异步方法
  635. /// </summary>
  636. /// <param name="request"></param>
  637. /// <param name="successCallback"></param>
  638. /// <param name="failCallback"></param>
  639. void CopyObject(CopyObjectRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  640. /// <summary>
  641. /// 拷贝一个分片
  642. /// </summary>
  643. /// <param name="request">UploadPartCopyRequest</param>
  644. /// <returns>UploadPartCopyResult</returns>
  645. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  646. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  647. UploadPartCopyResult PartCopy(UploadPartCopyRequest request);
  648. /// <summary>
  649. /// 拷贝一个分片的异步方法
  650. /// </summary>
  651. /// <param name="request"></param>
  652. /// <param name="successCallback"></param>
  653. /// <param name="failCallback"></param>
  654. void PartCopy(UploadPartCopyRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  655. /// <summary>
  656. /// 对象的跨域预请求
  657. /// </summary>
  658. /// <param name="request"></param>
  659. /// <returns></returns>
  660. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  661. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  662. OptionObjectResult OptionObject(OptionObjectRequest request);
  663. /// <summary>
  664. /// 对象的跨域预请求的异步方法
  665. /// </summary>
  666. /// <param name="request"></param>
  667. /// <param name="successCallback"></param>
  668. /// <param name="failCallback"></param>
  669. void OptionObject(OptionObjectRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  670. /// <summary>
  671. /// POST 方式上传对象
  672. /// </summary>
  673. /// <param name="request">PostObjectRequest</param>
  674. /// <returns>PostObjectResult</returns>
  675. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  676. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  677. PostObjectResult PostObject(PostObjectRequest request);
  678. /// <summary>
  679. /// POST 方式上传对象的异步方法
  680. /// </summary>
  681. /// <param name="request"></param>
  682. /// <param name="successCallback"></param>
  683. /// <param name="failCallback"></param>
  684. void PostObject(PostObjectRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  685. /// <summary>
  686. /// 对一个归档存储(ARCHIVE)类型的对象进行恢复
  687. /// </summary>
  688. /// <param name="request">RestoreObjectRequest</param>
  689. /// <returns>RestoreObjectResult</returns>
  690. /// <exception cref="COSXML.CosException.CosServerException">CosServerException</exception>
  691. /// <exception cref="COSXML.CosException.CosClientException">CosClientException</exception>
  692. RestoreObjectResult RestoreObject(RestoreObjectRequest request);
  693. /// <summary>
  694. /// 对一个归档存储(ARCHIVE)类型的对象进行恢复的异步方法
  695. /// </summary>
  696. /// <param name="request"></param>
  697. /// <param name="successCallback"></param>
  698. /// <param name="failCallback"></param>
  699. void RestoreObject(RestoreObjectRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  700. /// <summary>
  701. /// 设置存储桶静态网站
  702. /// </summary>
  703. /// <param name="request"></param>
  704. /// <returns>设置结果</returns>
  705. PutBucketWebsiteResult PutBucketWebsite(PutBucketWebsiteRequest request);
  706. /// <summary>
  707. /// 设置存储桶静态网站的异步方法
  708. /// </summary>
  709. /// <param name="request"></param>
  710. /// <param name="successCallback"></param>
  711. /// <param name="failCallback"></param>
  712. void PutBucketWebsiteAsync(PutBucketWebsiteRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  713. /// <summary>
  714. /// 获取存储桶静态网站设置
  715. /// </summary>
  716. /// <param name="request"></param>
  717. /// <returns>静态</returns>
  718. GetBucketWebsiteResult GetBucketWebsite(GetBucketWebsiteRequest request);
  719. /// <summary>
  720. /// 获取存储桶静态网站设置的异步方法
  721. /// </summary>
  722. /// <param name="request"></param>
  723. /// <param name="successCallback"></param>
  724. /// <param name="failCallback"></param>
  725. void GetBucketWebsiteAsync(GetBucketWebsiteRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  726. /// <summary>
  727. /// 删除存储桶静态网站设置
  728. /// </summary>
  729. /// <param name="request"></param>
  730. /// <returns></returns>
  731. DeleteBucketWebsiteResult DeleteBucketWebsite(DeleteBucketWebsiteRequest request);
  732. /// <summary>
  733. /// 删除存储桶静态网站设置的异步方法
  734. /// </summary>
  735. /// <param name="request"></param>
  736. /// <param name="successCallback"></param>
  737. /// <param name="failCallback"></param>
  738. void DeleteBucketWebsiteAsync(DeleteBucketWebsiteRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  739. /// <summary>
  740. /// 设置存储桶自定义域名
  741. /// </summary>
  742. /// <param name="request"></param>
  743. /// <returns></returns>
  744. PutBucketDomainResult PutBucketDomain(PutBucketDomainRequest request);
  745. /// <summary>
  746. /// 设置存储桶自定义域名的异步方法
  747. /// </summary>
  748. /// <param name="request"></param>
  749. /// <param name="successCallback"></param>
  750. /// <param name="failCallback"></param>
  751. void PutBucketDomainAsync(PutBucketDomainRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  752. /// <summary>
  753. /// 获取存储桶自定义域名
  754. /// </summary>
  755. /// <param name="request"></param>
  756. /// <returns></returns>
  757. GetBucketDomainResult GetBucketDomain(GetBucketDomainRequest request);
  758. /// <summary>
  759. /// 获取存储桶自定义域名的异步方法
  760. /// </summary>
  761. /// <param name="request"></param>
  762. /// <param name="successCallback"></param>
  763. /// <param name="failCallback"></param>
  764. void GetBucketDomainAsync(GetBucketDomainRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  765. /// <summary>
  766. /// 设置存储桶日志服务
  767. /// </summary>
  768. /// <param name="request"></param>
  769. /// <returns></returns>
  770. PutBucketLoggingResult PutBucketLogging(PutBucketLoggingRequest request);
  771. /// <summary>
  772. /// 设置存储桶日志服务的异步方法
  773. /// </summary>
  774. /// <param name="request"></param>
  775. /// <param name="successCallback"></param>
  776. /// <param name="failCallback"></param>
  777. void PutBucketLoggingAsync(PutBucketLoggingRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  778. /// <summary>
  779. /// 获取存储桶日志服务设置
  780. /// </summary>
  781. /// <param name="request"></param>
  782. /// <returns></returns>
  783. GetBucketLoggingResult GetBucketLogging(GetBucketLoggingRequest request);
  784. /// <summary>
  785. /// 获取存储桶日志服务设置的异步方法
  786. /// </summary>
  787. /// <param name="request"></param>
  788. /// <param name="successCallback"></param>
  789. /// <param name="failCallback"></param>
  790. void GetBucketLoggingAsync(GetBucketLoggingRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  791. /// <summary>
  792. /// 设置存储桶清单任务
  793. /// </summary>
  794. /// <param name="request"></param>
  795. /// <returns></returns>
  796. PutBucketInventoryResult PutBucketInventory(PutBucketInventoryRequest request);
  797. /// <summary>
  798. /// 设置存储桶清单任务的异步方法
  799. /// </summary>
  800. /// <param name="request"></param>
  801. /// <param name="successCallback"></param>
  802. /// <param name="failCallback"></param>
  803. void PutBucketInventoryAsync(PutBucketInventoryRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  804. /// <summary>
  805. /// 获取存储桶清单任务
  806. /// </summary>
  807. /// <param name="request"></param>
  808. /// <returns></returns>
  809. GetBucketInventoryResult GetBucketInventory(GetBucketInventoryRequest request);
  810. /// <summary>
  811. /// 获取存储桶清单任务的异步方法
  812. /// </summary>
  813. /// <param name="request"></param>
  814. /// <param name="successCallback"></param>
  815. /// <param name="failCallback"></param>
  816. void GetBucketInventoryAsync(GetBucketInventoryRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  817. /// <summary>
  818. /// 删除存储桶清单任务
  819. /// </summary>
  820. /// <param name="request"></param>
  821. /// <returns></returns>
  822. DeleteBucketInventoryResult DeleteBucketInventory(DeleteBucketInventoryRequest request);
  823. /// <summary>
  824. /// 删除存储桶清单任务的异步方法
  825. /// </summary>
  826. /// <param name="request"></param>
  827. /// <param name="successCallback"></param>
  828. /// <param name="failCallback"></param>
  829. void DeleteInventoryAsync(DeleteBucketInventoryRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  830. /// <summary>
  831. /// 列出存储桶所有清单任务
  832. /// </summary>
  833. /// <param name="request"></param>
  834. /// <returns></returns>
  835. ListBucketInventoryResult ListBucketInventory(ListBucketInventoryRequest request);
  836. /// <summary>
  837. /// 列出存储桶所有清单任务的异步方法
  838. /// </summary>
  839. /// <param name="request"></param>
  840. /// <param name="successCallback"></param>
  841. /// <param name="failCallback"></param>
  842. void ListBucketInventoryAsync(ListBucketInventoryRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  843. /// <summary>
  844. /// 设置存储桶标签
  845. /// </summary>
  846. /// <param name="request"></param>
  847. /// <returns></returns>
  848. PutBucketTaggingResult PutBucketTagging(PutBucketTaggingRequest request);
  849. /// <summary>
  850. /// 设置存储桶标签的异步方法
  851. /// </summary>
  852. /// <param name="request"></param>
  853. /// <param name="successCallback"></param>
  854. /// <param name="failCallback"></param>
  855. void PutBucketTaggingAsync(PutBucketTaggingRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  856. /// <summary>
  857. /// 获取存储桶标签
  858. /// </summary>
  859. /// <param name="request"></param>
  860. /// <returns></returns>
  861. GetBucketTaggingResult GetBucketTagging(GetBucketTaggingRequest request);
  862. /// <summary>
  863. /// 获取存储桶标签的异步方法
  864. /// </summary>
  865. /// <param name="request"></param>
  866. /// <param name="successCallback"></param>
  867. /// <param name="failCallback"></param>
  868. void GetBucketTaggingAsync(GetBucketTaggingRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  869. /// <summary>
  870. /// 删除存储桶标签
  871. /// </summary>
  872. /// <param name="request"></param>
  873. /// <returns></returns>
  874. DeleteBucketTaggingResult DeleteBucketTagging(DeleteBucketTaggingRequest request);
  875. /// <summary>
  876. /// 删除存储桶标签的异步方法
  877. /// </summary>
  878. /// <param name="request"></param>
  879. /// <param name="successCallback"></param>
  880. /// <param name="failCallback"></param>
  881. void DeleteBucketTaggingAsync(DeleteBucketTaggingRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  882. /// <summary>
  883. /// 检索对象
  884. /// </summary>
  885. /// <param name="request"></param>
  886. /// <returns></returns>
  887. SelectObjectResult SelectObject(SelectObjectRequest request);
  888. /// <summary>
  889. /// 检索对象的异步方法
  890. /// </summary>
  891. /// <param name="request"></param>
  892. /// <param name="successCallback"></param>
  893. /// <param name="failCallback"></param>
  894. void SelectObjectAsync(SelectObjectRequest request, COSXML.Callback.OnSuccessCallback<CosResult> successCallback, COSXML.Callback.OnFailedCallback failCallback);
  895. /// <summary>
  896. /// 获取智能分层配置
  897. /// </summary>
  898. /// <param name="request"></param>
  899. GetBucketIntelligentTieringResult GetBucketIntelligentTieringConfiguration(GetBucketIntelligentTieringRequest request);
  900. /// <summary>
  901. /// 设置存储桶智能分层
  902. /// </summary>
  903. /// <param name="request"></param>
  904. CosResult PutBucketIntelligentTiering(PutBucketIntelligentTieringRequest request);
  905. /// <summary>
  906. /// 内容识别
  907. /// </summary>
  908. /// <param name="request"></param>
  909. /// <returns></returns>
  910. SensitiveContentRecognitionResult SensitiveContentRecognition(SensitiveContentRecognitionRequest request);
  911. /// <summary>
  912. /// 图片处理
  913. /// </summary>
  914. /// <param name="request"></param>
  915. /// <returns></returns>
  916. ImageProcessResult ImageProcess(ImageProcessRequest request);
  917. /// <summary>
  918. /// 下载时进行二维码识别
  919. /// </summary>
  920. /// <param name="request"></param>
  921. /// <returns></returns>
  922. QRCodeRecognitionResult QRCodeRecognition(QRCodeRecognitionRequest request);
  923. /// <summary>
  924. /// 获取媒体文件某个时间的截图
  925. /// </summary>
  926. /// <param name="request"></param>
  927. /// <returns></returns>
  928. GetSnapshotResult GetSnapshot(GetSnapshotRequest request);
  929. /// <summary>
  930. /// 获取媒体文件的信息
  931. /// </summary>
  932. /// <param name="request"></param>
  933. /// <returns></returns>
  934. GetMediaInfoResult GetMediaInfo(GetMediaInfoRequest request);
  935. /// <summary>
  936. /// 提交视频审核任务
  937. /// </summary>
  938. /// <param name="request"></param>
  939. /// <returns></returns>
  940. SubmitCensorJobResult SubmitVideoCensorJob(SubmitVideoCensorJobRequest request);
  941. /// <summary>
  942. /// 获取视频审核任务结果
  943. /// </summary>
  944. /// <param name="request"></param>
  945. /// <returns></returns>
  946. GetVideoCensorJobResult GetVideoCensorJob(GetVideoCensorJobRequest request);
  947. /// <summary>
  948. /// 提交音频审核任务
  949. /// </summary>
  950. /// <param name="request"></param>
  951. /// <returns></returns>
  952. SubmitCensorJobResult SubmitAudioCensorJob(SubmitAudioCensorJobRequest request);
  953. /// <summary>
  954. /// 获取音频审核任务结果
  955. /// </summary>
  956. /// <param name="request"></param>
  957. /// <returns></returns>
  958. GetAudioCensorJobResult GetAudioCensorJob(GetAudioCensorJobRequest request);
  959. /// <summary>
  960. /// 提交文本审核任务
  961. /// </summary>
  962. /// <param name="request"></param>
  963. /// <returns></returns>
  964. SubmitCensorJobResult SubmitTextCensorJob(SubmitTextCensorJobRequest request);
  965. /// <summary>
  966. /// 提交文本审核任务, 支持同步返回
  967. /// </summary>
  968. /// <param name="request"></param>
  969. /// <returns></returns>
  970. SubmitTextCensorJobsResult SubmitTextCensorJobSync(SubmitTextCensorJobRequest request);
  971. /// <summary>
  972. /// 获取文本审核任务结果
  973. /// </summary>
  974. /// <param name="request"></param>
  975. /// <returns></returns>
  976. GetTextCensorJobResult GetTextCensorJob(GetTextCensorJobRequest request);
  977. /// <summary>
  978. /// 提交文档审核任务
  979. /// </summary>
  980. /// <param name="request"></param>
  981. /// <returns></returns>
  982. SubmitCensorJobResult SubmitDocumentCensorJob(SubmitDocumentCensorJobRequest request);
  983. /// <summary>
  984. /// 获取文档审核任务结果
  985. /// </summary>
  986. /// <param name="request"></param>
  987. /// <returns></returns>
  988. GetDocumentCensorJobResult GetDocumentCensorJob(GetDocumentCensorJobRequest request);
  989. /// <summary>
  990. /// 获取媒体bucket列表
  991. /// </summary>
  992. /// <param name="request"></param>
  993. /// <returns></returns>
  994. DescribeMediaBucketsResult DescribeMediaBuckets(DescribeMediaBucketsRequest request);
  995. /// <summary>
  996. /// 取消请求
  997. /// </summary>
  998. /// <param name="cosRequest"></param>
  999. void Cancel(CosRequest cosRequest);
  1000. /// <summary>
  1001. /// 同步执行请求
  1002. /// </summary>
  1003. /// <param name="request"></param>
  1004. /// <returns></returns>
  1005. T Execute<T>(CosRequest request) where T : CosResult;
  1006. #if !COMPATIBLE
  1007. /// <summary>
  1008. /// 异步执行请求
  1009. /// </summary>
  1010. /// <param name="request"></param>
  1011. /// <returns></returns>
  1012. Task<T> ExecuteAsync<T>(CosRequest request) where T : CosResult;
  1013. #endif
  1014. }
  1015. }