google-cloud-cpp icon indicating copy to clipboard operation
google-cloud-cpp copied to clipboard

Clean up deduplicated operation stubs in stub_generator

Open cuiy0006 opened this issue 1 year ago • 0 comments

class DefaultDataMigrationServiceStub : public DataMigrationServiceStub {
 public:
  DefaultDataMigrationServiceStub(
      std::unique_ptr<
          google::cloud::clouddms::v1::DataMigrationService::StubInterface>
          grpc_stub,
      std::unique_ptr<google::longrunning::Operations::StubInterface>
          operations_stub,
      std::unique_ptr<google::iam::v1::IAMPolicy::StubInterface> iampolicy_stub,
      std::unique_ptr<google::cloud::location::Locations::StubInterface>
          locations_stub,
      std::unique_ptr<google::longrunning::Operations::StubInterface>
          operations)
      : grpc_stub_(std::move(grpc_stub)),
        operations_stub_(std::move(operations_stub)),
        iampolicy_stub_(std::move(iampolicy_stub)),
        locations_stub_(std::move(locations_stub)),
        operations_(std::move(operations)) {}

After adding mixin, there could be multiple operation stubs like operations_stub_ and operations_, we can change stub_generator.cc to keep one of them.

cuiy0006 avatar Sep 30 '24 22:09 cuiy0006