blob: 9dbb375e8ee4c7e9a464c9d55be51079dc1a5234 [file] [log] [blame]
Andrea Campanellac795b7d2021-04-14 13:24:44 +02001// Generated by the gRPC C++ plugin.
2// If you make any local change, they will be lost.
3// source: dmi/hw_metrics_mgmt_service.proto
4
5#include "dmi/hw_metrics_mgmt_service.pb.h"
6#include "dmi/hw_metrics_mgmt_service.grpc.pb.h"
7
Andrea Campanellafb09e7e2021-04-26 17:22:49 +00008#include <grpc++/impl/codegen/async_stream.h>
9#include <grpc++/impl/codegen/async_unary_call.h>
10#include <grpc++/impl/codegen/channel_interface.h>
11#include <grpc++/impl/codegen/client_unary_call.h>
12#include <grpc++/impl/codegen/method_handler_impl.h>
13#include <grpc++/impl/codegen/rpc_service_method.h>
14#include <grpc++/impl/codegen/service_type.h>
15#include <grpc++/impl/codegen/sync_stream.h>
Andrea Campanellac795b7d2021-04-14 13:24:44 +020016namespace dmi {
17
18static const char* NativeMetricsManagementService_method_names[] = {
19 "/dmi.NativeMetricsManagementService/ListMetrics",
20 "/dmi.NativeMetricsManagementService/UpdateMetricsConfiguration",
21 "/dmi.NativeMetricsManagementService/GetMetric",
Chandrakanth Nalkudre Gowda68590a42021-04-22 15:19:21 +053022 "/dmi.NativeMetricsManagementService/StreamMetrics",
Andrea Campanellac795b7d2021-04-14 13:24:44 +020023};
24
25std::unique_ptr< NativeMetricsManagementService::Stub> NativeMetricsManagementService::NewStub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options) {
Andrea Campanellac795b7d2021-04-14 13:24:44 +020026 std::unique_ptr< NativeMetricsManagementService::Stub> stub(new NativeMetricsManagementService::Stub(channel));
27 return stub;
28}
29
30NativeMetricsManagementService::Stub::Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel)
Andrea Campanellafb09e7e2021-04-26 17:22:49 +000031 : channel_(channel), rpcmethod_ListMetrics_(NativeMetricsManagementService_method_names[0], ::grpc::RpcMethod::NORMAL_RPC, channel)
32 , rpcmethod_UpdateMetricsConfiguration_(NativeMetricsManagementService_method_names[1], ::grpc::RpcMethod::NORMAL_RPC, channel)
33 , rpcmethod_GetMetric_(NativeMetricsManagementService_method_names[2], ::grpc::RpcMethod::NORMAL_RPC, channel)
34 , rpcmethod_StreamMetrics_(NativeMetricsManagementService_method_names[3], ::grpc::RpcMethod::SERVER_STREAMING, channel)
Andrea Campanellac795b7d2021-04-14 13:24:44 +020035 {}
36
37::grpc::Status NativeMetricsManagementService::Stub::ListMetrics(::grpc::ClientContext* context, const ::dmi::HardwareID& request, ::dmi::ListMetricsResponse* response) {
Andrea Campanellafb09e7e2021-04-26 17:22:49 +000038 return ::grpc::BlockingUnaryCall(channel_.get(), rpcmethod_ListMetrics_, context, request, response);
Andrea Campanellac795b7d2021-04-14 13:24:44 +020039}
40
41::grpc::ClientAsyncResponseReader< ::dmi::ListMetricsResponse>* NativeMetricsManagementService::Stub::AsyncListMetricsRaw(::grpc::ClientContext* context, const ::dmi::HardwareID& request, ::grpc::CompletionQueue* cq) {
Andrea Campanellafb09e7e2021-04-26 17:22:49 +000042 return new ::grpc::ClientAsyncResponseReader< ::dmi::ListMetricsResponse>(channel_.get(), cq, rpcmethod_ListMetrics_, context, request);
Andrea Campanellac795b7d2021-04-14 13:24:44 +020043}
44
45::grpc::Status NativeMetricsManagementService::Stub::UpdateMetricsConfiguration(::grpc::ClientContext* context, const ::dmi::MetricsConfigurationRequest& request, ::dmi::MetricsConfigurationResponse* response) {
Andrea Campanellafb09e7e2021-04-26 17:22:49 +000046 return ::grpc::BlockingUnaryCall(channel_.get(), rpcmethod_UpdateMetricsConfiguration_, context, request, response);
Andrea Campanellac795b7d2021-04-14 13:24:44 +020047}
48
49::grpc::ClientAsyncResponseReader< ::dmi::MetricsConfigurationResponse>* NativeMetricsManagementService::Stub::AsyncUpdateMetricsConfigurationRaw(::grpc::ClientContext* context, const ::dmi::MetricsConfigurationRequest& request, ::grpc::CompletionQueue* cq) {
Andrea Campanellafb09e7e2021-04-26 17:22:49 +000050 return new ::grpc::ClientAsyncResponseReader< ::dmi::MetricsConfigurationResponse>(channel_.get(), cq, rpcmethod_UpdateMetricsConfiguration_, context, request);
Andrea Campanellac795b7d2021-04-14 13:24:44 +020051}
52
53::grpc::Status NativeMetricsManagementService::Stub::GetMetric(::grpc::ClientContext* context, const ::dmi::GetMetricRequest& request, ::dmi::GetMetricResponse* response) {
Andrea Campanellafb09e7e2021-04-26 17:22:49 +000054 return ::grpc::BlockingUnaryCall(channel_.get(), rpcmethod_GetMetric_, context, request, response);
Andrea Campanellac795b7d2021-04-14 13:24:44 +020055}
56
57::grpc::ClientAsyncResponseReader< ::dmi::GetMetricResponse>* NativeMetricsManagementService::Stub::AsyncGetMetricRaw(::grpc::ClientContext* context, const ::dmi::GetMetricRequest& request, ::grpc::CompletionQueue* cq) {
Andrea Campanellafb09e7e2021-04-26 17:22:49 +000058 return new ::grpc::ClientAsyncResponseReader< ::dmi::GetMetricResponse>(channel_.get(), cq, rpcmethod_GetMetric_, context, request);
Andrea Campanellac795b7d2021-04-14 13:24:44 +020059}
60
Chandrakanth Nalkudre Gowda68590a42021-04-22 15:19:21 +053061::grpc::ClientReader< ::dmi::Metric>* NativeMetricsManagementService::Stub::StreamMetricsRaw(::grpc::ClientContext* context, const ::google::protobuf::Empty& request) {
Andrea Campanellafb09e7e2021-04-26 17:22:49 +000062 return new ::grpc::ClientReader< ::dmi::Metric>(channel_.get(), rpcmethod_StreamMetrics_, context, request);
Chandrakanth Nalkudre Gowda68590a42021-04-22 15:19:21 +053063}
64
65::grpc::ClientAsyncReader< ::dmi::Metric>* NativeMetricsManagementService::Stub::AsyncStreamMetricsRaw(::grpc::ClientContext* context, const ::google::protobuf::Empty& request, ::grpc::CompletionQueue* cq, void* tag) {
Andrea Campanellafb09e7e2021-04-26 17:22:49 +000066 return new ::grpc::ClientAsyncReader< ::dmi::Metric>(channel_.get(), cq, rpcmethod_StreamMetrics_, context, request, tag);
Chandrakanth Nalkudre Gowda68590a42021-04-22 15:19:21 +053067}
68
Andrea Campanellac795b7d2021-04-14 13:24:44 +020069NativeMetricsManagementService::Service::Service() {
Andrea Campanellafb09e7e2021-04-26 17:22:49 +000070 AddMethod(new ::grpc::RpcServiceMethod(
Andrea Campanellac795b7d2021-04-14 13:24:44 +020071 NativeMetricsManagementService_method_names[0],
Andrea Campanellafb09e7e2021-04-26 17:22:49 +000072 ::grpc::RpcMethod::NORMAL_RPC,
73 new ::grpc::RpcMethodHandler< NativeMetricsManagementService::Service, ::dmi::HardwareID, ::dmi::ListMetricsResponse>(
74 std::mem_fn(&NativeMetricsManagementService::Service::ListMetrics), this)));
75 AddMethod(new ::grpc::RpcServiceMethod(
Andrea Campanellac795b7d2021-04-14 13:24:44 +020076 NativeMetricsManagementService_method_names[1],
Andrea Campanellafb09e7e2021-04-26 17:22:49 +000077 ::grpc::RpcMethod::NORMAL_RPC,
78 new ::grpc::RpcMethodHandler< NativeMetricsManagementService::Service, ::dmi::MetricsConfigurationRequest, ::dmi::MetricsConfigurationResponse>(
79 std::mem_fn(&NativeMetricsManagementService::Service::UpdateMetricsConfiguration), this)));
80 AddMethod(new ::grpc::RpcServiceMethod(
Andrea Campanellac795b7d2021-04-14 13:24:44 +020081 NativeMetricsManagementService_method_names[2],
Andrea Campanellafb09e7e2021-04-26 17:22:49 +000082 ::grpc::RpcMethod::NORMAL_RPC,
83 new ::grpc::RpcMethodHandler< NativeMetricsManagementService::Service, ::dmi::GetMetricRequest, ::dmi::GetMetricResponse>(
84 std::mem_fn(&NativeMetricsManagementService::Service::GetMetric), this)));
85 AddMethod(new ::grpc::RpcServiceMethod(
Chandrakanth Nalkudre Gowda68590a42021-04-22 15:19:21 +053086 NativeMetricsManagementService_method_names[3],
Andrea Campanellafb09e7e2021-04-26 17:22:49 +000087 ::grpc::RpcMethod::SERVER_STREAMING,
88 new ::grpc::ServerStreamingHandler< NativeMetricsManagementService::Service, ::google::protobuf::Empty, ::dmi::Metric>(
89 std::mem_fn(&NativeMetricsManagementService::Service::StreamMetrics), this)));
Andrea Campanellac795b7d2021-04-14 13:24:44 +020090}
91
92NativeMetricsManagementService::Service::~Service() {
93}
94
95::grpc::Status NativeMetricsManagementService::Service::ListMetrics(::grpc::ServerContext* context, const ::dmi::HardwareID* request, ::dmi::ListMetricsResponse* response) {
96 (void) context;
97 (void) request;
98 (void) response;
99 return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
100}
101
102::grpc::Status NativeMetricsManagementService::Service::UpdateMetricsConfiguration(::grpc::ServerContext* context, const ::dmi::MetricsConfigurationRequest* request, ::dmi::MetricsConfigurationResponse* response) {
103 (void) context;
104 (void) request;
105 (void) response;
106 return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
107}
108
109::grpc::Status NativeMetricsManagementService::Service::GetMetric(::grpc::ServerContext* context, const ::dmi::GetMetricRequest* request, ::dmi::GetMetricResponse* response) {
110 (void) context;
111 (void) request;
112 (void) response;
113 return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
114}
115
Chandrakanth Nalkudre Gowda68590a42021-04-22 15:19:21 +0530116::grpc::Status NativeMetricsManagementService::Service::StreamMetrics(::grpc::ServerContext* context, const ::google::protobuf::Empty* request, ::grpc::ServerWriter< ::dmi::Metric>* writer) {
117 (void) context;
118 (void) request;
119 (void) writer;
120 return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
121}
122
Andrea Campanellac795b7d2021-04-14 13:24:44 +0200123
124} // namespace dmi
125