service_op.h 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. // Copyright (c) 2017, Tencent Inc.
  2. // All rights reserved.
  3. //
  4. // Author: sevenyou <sevenyou@tencent.com>
  5. // Created: 11/14/17
  6. // Description:
  7. #ifndef SERVICEOP_H
  8. #define SERVICEOP_H
  9. #pragma once
  10. #include "cos_sys_config.h"
  11. #include "op/base_op.h"
  12. #include "op/cos_result.h"
  13. #include "request/service_req.h"
  14. #include "response/service_resp.h"
  15. namespace qcloud_cos {
  16. /// \brief 封装了Service相关的操作
  17. class ServiceOp : public BaseOp {
  18. public:
  19. /// \brief ServiceOp构造函数
  20. ///
  21. /// \param cos_conf Cos配置
  22. explicit ServiceOp(const SharedConfig& config) : BaseOp(config) {}
  23. /// \brief ServiceOp析构函数
  24. virtual ~ServiceOp() {}
  25. /// \brief 获取请求者名下的所有存储空间列表Bucket list
  26. /// (详见:https://cloud.tencent.com/document/api/436/8291)
  27. ///
  28. /// \param req GetService请求
  29. /// \param resp GetService返回
  30. ///
  31. /// \return 本次请求的调用情况(如状态码等)
  32. CosResult GetService(const GetServiceReq& req, GetServiceResp* resp);
  33. };
  34. } // namespace qcloud_cos
  35. #endif // SERVICEOP_H