Viam C++ SDK current
Loading...
Searching...
No Matches
generic_server.hpp
1
4#pragma once
5
6#include <viam/api/common/v1/common.grpc.pb.h>
7#include <viam/api/service/generic/v1/generic.grpc.pb.h>
8
10#include <viam/sdk/resource/resource_server_base.hpp>
11#include <viam/sdk/services/generic.hpp>
12
13namespace viam {
14namespace sdk {
15namespace impl {
16
21 public viam::service::generic::v1::GenericService::Service {
22 public:
24 using service_type = service::generic::v1::GenericService;
25 explicit GenericServiceServer(std::shared_ptr<ResourceManager> manager);
26
27 ::grpc::Status DoCommand(::grpc::ServerContext* context,
28 const ::viam::common::v1::DoCommandRequest* request,
29 ::viam::common::v1::DoCommandResponse* response) noexcept override;
30};
31
32} // namespace impl
33} // namespace sdk
34} // namespace viam
A GenericService represents any service that can execute arbitrary commands.
Definition generic.hpp:21
Definition resource_server_base.hpp:8
gRPC server implementation of a GenericService.
Definition generic_server.hpp:21
Defines a general-purpose resource manager.