添加 CMake 配置以支持插件宿主和操作系统检测,调整项目结构

This commit is contained in:
2025-08-13 18:12:45 +08:00
parent 5d85bf494f
commit 7732bcf241
20 changed files with 133 additions and 14968 deletions

View File

@@ -15,13 +15,15 @@
# --- 项目基础设置 (Basic Project Setup) ---
# 定义了项目构建所需的最低 CMake 版本和项目名称。
cmake_minimum_required(VERSION 3.14)
project(PikoEngine)
project(PikoBackend)
# --- 自定义脚本与配置 (Custom Scripts & Configuration) ---
# 引入外部 CMake 脚本模块以处理通用任务,保持主脚本的整洁。
include(../cmake_script/project_cpp_standard.cmake) # 负责设置 C++ 标准。
include(../cmake_script/retrieve_files.cmake) # 负责递归查找源文件。
include(../cmake_script/utils.cmake) # 提供其他工具函数,如 compile_proto_files。
include(cmake_script/project_cpp_standard.cmake) # 负责设置 C++ 标准。
include(cmake_script/retrieve_files.cmake) # 负责递归查找源文件。
include(cmake_script/utils.cmake) # 提供其他工具函数,如 compile_proto_files。
include(cmake_script/detect_os.cmake)
include(cmake_script/plugin_host_register.cmake)
# 使用自定义函数来配置项目的编译选项。
# @param STANDARD: 指定C++语言标准,此处为 C++23。
@@ -41,16 +43,6 @@ set(CMAKE_BINARY_DIR ${CMAKE_SOURCE_DIR}/../../build/${CMAKE_BUILD_TYPE})
# 调用自定义函数为项目配置默认的编译器警告、输出路径等。
configure_project_defaults()
# --- 源代码文件管理 (Source File Management) ---
# 初始化一个变量用于存储所有源文件的路径。
set(SRC_FILES "")
# 调用自定义函数递归地从 'src' 目录中检索所有源文件,
# 并将文件列表追加到 SRC_FILES 变量中。
# @param CMAKE_CURRENT_SOURCE_DIR/src: 要搜索的源文件根目录。
# @param SRC_FILES: 用于接收文件列表的输出变量。
retrieve_files(${CMAKE_CURRENT_SOURCE_DIR}/src SRC_FILES)
# --- 依赖库查找 (Dependency Discovery) ---
# 查找项目所需的核心第三方库。`REQUIRED` 参数表示如果找不到库CMake 将会报错并停止构建。
find_package(gRPC CONFIG REQUIRED)
@@ -65,30 +57,12 @@ find_package(ZeroMQ CONFIG REQUIRED)
# @param OUTPUT_PATH: 生成的 .pb.h, .pb.cc, .grpc.pb.h, .grpc.pb.cc 文件的输出目录。
# @param GRPC_ENABLED: 设置为 TRUE表示同时生成 gRPC 服务相关的代码。
compile_proto_files(
TARGET_NAME ${PROJECT_NAME}_proto
TARGET_NAME piko_proto
PROTO_PATH ${CMAKE_CURRENT_SOURCE_DIR}/../proto
OUTPUT_PATH ${CMAKE_CURRENT_SOURCE_DIR}/proto
GRPC_ENABLED TRUE
)
# --- 可执行文件目标定义 (Executable Target Definition) ---
# 创建一个名为 NinaEngine (与项目名相同) 的可执行文件。
# @param ${PROJECT_NAME}: 目标名称。
# @param ${SRC_FILES}: 构成该目标的所有源文件。
add_executable(${PROJECT_NAME} ${SRC_FILES})
# 将依赖库链接到我们的可执行文件目标。
# @param ${PROJECT_NAME}: 要链接的目标。
# @param PRIVATE: 表示链接的依赖项仅对 ${PROJECT_NAME} 自身可见,
# 不会传递给链接到 ${PROJECT_NAME} 的其他目标。
# @param config_target: 链接之前创建的接口目标,以应用通用的编译设置。
# @param gRPC::grpc++: gRPC 库提供的 C++ 目标。
# @param protobuf::libprotobuf: Protobuf 运行时库目标。
# @param zmq: ZeroMQ 库目标。
target_link_libraries(${PROJECT_NAME} PRIVATE
config_target
gRPC::grpc++
protobuf::libprotobuf
libzmq
${PROJECT_NAME}_proto
)
add_subdirectory(src/vst2_host)
add_subdirectory(src/vst3_host)
add_subdirectory(src/engine)

View File

@@ -0,0 +1,65 @@
#=============================================================================
# 函数: register_plugin_host
# 描述: 注册一个插件宿主目标。此函数将目标名称添加到一个全局列表中,
# 以便后续可以将其作为其他目标的依赖。
# 参数:
# IN_TARGET - (必需) 要注册的插件宿主的可执行文件目标名称。
#=============================================================================
function(register_plugin_host IN_TARGET)
# 检查输入参数
if(NOT IN_TARGET)
message(FATAL_ERROR "函数 'register_plugin_host' 必须传入 IN_TARGET 参数。")
endif()
# 从全局属性中获取当前已注册的目标列表
get_property(CURRENT_HOSTS GLOBAL PROPERTY _PLUGIN_HOST_TARGETS_LIST DEFINED)
# 检查目标是否已注册,防止重复添加
if(CURRENT_HOSTS)
list(FIND CURRENT_HOSTS ${IN_TARGET} EXISTING_INDEX)
if(EXISTING_INDEX GREATER -1)
message(NOTICE "插件宿主目标 '${IN_TARGET}' 已被注册,将跳过。")
return()
endif()
endif()
# 向全局属性的列表中追加新的目标名称
# 注意: set_property 的 APPEND 行为会将值附加到现有字符串后面以分号分隔这正是CMake列表的格式
set_property(GLOBAL APPEND PROPERTY _PLUGIN_HOST_TARGETS_LIST ${IN_TARGET})
message(STATUS "已注册插件宿主: ${IN_TARGET}")
endfunction()
#=============================================================================
# 函数: add_plugin_host_dependency
# 描述: 将所有已注册的插件宿主目标作为指定目标的依赖项。
# 这确保在构建主引擎之前,所有插件宿主都已被编译。
# 参数:
# IN_TARGET - (必需) 需要依赖插件宿主的目标名称 (例如: 主引擎目标)。
#=============================================================================
function(add_plugin_host_dependency IN_TARGET)
# 检查输入参数
if(NOT IN_TARGET)
message(FATAL_ERROR "函数 'add_plugin_host_dependency' 必须传入 IN_TARGET 参数。")
endif()
# 从全局属性中获取完整的目标列表
get_property(ALL_HOSTS GLOBAL PROPERTY _PLUGIN_HOST_TARGETS_LIST)
# 如果列表为空,则无需执行任何操作
if(NOT ALL_HOSTS)
message(NOTICE "未找到注册的插件宿主目标,无需添加依赖。")
return()
endif()
# 遍历所有注册的宿主目标,并添加依赖关系
foreach(HOST_TARGET ${ALL_HOSTS})
# 在添加依赖前,最好再次确认目标确实存在
if(TARGET ${HOST_TARGET})
add_dependencies(${IN_TARGET} ${HOST_TARGET})
message(STATUS "为 '${IN_TARGET}' 添加依赖 -> ${HOST_TARGET}")
else()
message(WARNING "尝试为 '${IN_TARGET}' 添加不存在的依赖目标 '${HOST_TARGET}'。请检查编译顺序。")
endif()
endforeach()
endfunction()

View File

@@ -0,0 +1,34 @@
project(PikoEngine)
# --- 源代码文件管理 (Source File Management) ---
# 初始化一个变量用于存储所有源文件的路径。
set(SRC_FILES "")
# 调用自定义函数递归地从 'src' 目录中检索所有源文件,
# 并将文件列表追加到 SRC_FILES 变量中。
# @param CMAKE_CURRENT_SOURCE_DIR/src: 要搜索的源文件根目录。
# @param SRC_FILES: 用于接收文件列表的输出变量。
retrieve_files(${CMAKE_CURRENT_SOURCE_DIR}/src SRC_FILES)
# --- 可执行文件目标定义 (Executable Target Definition) ---
# 创建一个名为 NinaEngine (与项目名相同) 的可执行文件。
# @param ${PROJECT_NAME}: 目标名称。
# @param ${SRC_FILES}: 构成该目标的所有源文件。
add_executable(${PROJECT_NAME} ${SRC_FILES})
add_plugin_host_dependency(${PROJECT_NAME})
# 将依赖库链接到我们的可执行文件目标。
# @param ${PROJECT_NAME}: 要链接的目标。
# @param PRIVATE: 表示链接的依赖项仅对 ${PROJECT_NAME} 自身可见,
# 不会传递给链接到 ${PROJECT_NAME} 的其他目标。
# @param config_target: 链接之前创建的接口目标,以应用通用的编译设置。
# @param gRPC::grpc++: gRPC 库提供的 C++ 目标。
# @param protobuf::libprotobuf: Protobuf 运行时库目标。
# @param zmq: ZeroMQ 库目标。
target_link_libraries(${PROJECT_NAME} PRIVATE
config_target
gRPC::grpc++
protobuf::libprotobuf
libzmq
piko_proto
)

View File

@@ -11,4 +11,11 @@ set(SRC_FILES "")
retrieve_files(${CMAKE_CURRENT_SOURCE_DIR}/src SRC_FILES)
add_executable(${PROJECT_NAME} ${SRC_FILES})
setup_host_project(${PROJECT_NAME})
target_link_libraries(${PROJECT_NAME} PRIVATE
config_target
piko_proto
gRPC::grpc++
protobuf::libprotobuf
libzmq
)
register_plugin_host(${PROJECT_NAME})

View File

@@ -11,4 +11,11 @@ set(SRC_FILES "")
retrieve_files(${CMAKE_CURRENT_SOURCE_DIR}/src SRC_FILES)
add_executable(${PROJECT_NAME} ${SRC_FILES})
setup_host_project(${PROJECT_NAME})
target_link_libraries(${PROJECT_NAME} PRIVATE
config_target
piko_proto
gRPC::grpc++
protobuf::libprotobuf
libzmq
)
register_plugin_host(${PROJECT_NAME})

View File

@@ -0,0 +1,8 @@
//
// Created by A on 2025/8/13.
//
int main(int argc, char *argv[])
{
return 0;
}

View File

@@ -1,50 +0,0 @@
cmake_minimum_required(VERSION 3.14)
project(PikoPluginHost)
# --- 自定义脚本与配置 (Custom Scripts & Configuration) ---
# 引入外部 CMake 脚本模块以处理通用任务,保持主脚本的整洁。
include(../cmake_script/project_cpp_standard.cmake) # 负责设置 C++ 标准。
include(../cmake_script/retrieve_files.cmake) # 负责递归查找源文件。
include(../cmake_script/utils.cmake) # 提供其他工具函数,如 compile_proto_files。
include(cmake_script/plugin_host_project.cmake)
# 使用自定义函数来配置项目的编译选项。
# @param STANDARD: 指定C++语言标准,此处为 C++23。
# @param INTERFACE_TARGET: 创建一个名为 config_target 的 INTERFACE 目标,
# 用于传递编译选项、宏定义等,方便统一管理。
setup_project_options(
STANDARD 23
INTERFACE_TARGET config_target
)
# NOTE: 硬编码构建目录可能会降低灵活性。
# 通常,更推荐的做法是让用户在调用 CMake 时通过 -B <build_dir> 参数来指定构建目录,
# 以支持灵活的 out-of-source builds。
# 此处强制将构建目录设置在项目根目录的上一级中的 `build` 文件夹。
set(CMAKE_BINARY_DIR ${CMAKE_SOURCE_DIR}/../../build/${CMAKE_BUILD_TYPE})
# 调用自定义函数为项目配置默认的编译器警告、输出路径等。
configure_project_defaults()
# --- 依赖库查找 (Dependency Discovery) ---
# 查找项目所需的核心第三方库。`REQUIRED` 参数表示如果找不到库CMake 将会报错并停止构建。
find_package(gRPC CONFIG REQUIRED)
find_package(Protobuf CONFIG REQUIRED)
find_package(ZeroMQ CONFIG REQUIRED)
# --- Protocol Buffers 编译 (Protocol Buffers Compilation) ---
# 使用自定义函数编译 .proto 文件,自动生成 C++ 源代码和 gRPC 服务代码。
# 这是一个典型的代码生成步骤,需要在编译主程序源代码之前完成。
# @param TARGET_NAME: 为生成的代码创建一个内部目标名称,用于依赖管理。
# @param PROTO_PATH: 存放 .proto 定义文件的目录。
# @param OUTPUT_PATH: 生成的 .pb.h, .pb.cc, .grpc.pb.h, .grpc.pb.cc 文件的输出目录。
# @param GRPC_ENABLED: 设置为 TRUE表示同时生成 gRPC 服务相关的代码。
compile_proto_files(
TARGET_NAME plugin_host_proto
PROTO_PATH ${CMAKE_CURRENT_SOURCE_DIR}/../proto
OUTPUT_PATH ${CMAKE_CURRENT_SOURCE_DIR}/src/proto
GRPC_ENABLED TRUE
)
add_subdirectory(src/vst2)
add_subdirectory(src/vst3)

View File

@@ -1,15 +0,0 @@
function(setup_host_project IN_PROJECT_NAME)
# --- 目标依赖关系 (Target Dependencies) ---
# 显式声明主目标对 proto 代码生成目标的依赖。
# 这确保了在编译 NinaEngine 之前,所有 .proto 文件都已经被成功编译和生成。
# 如果没有这个依赖关系,构建可能会因为找不到生成的头文件而失败。
# add_dependencies(${IN_PROJECT_NAME} plugin_host_proto)
target_link_libraries(${IN_PROJECT_NAME} PRIVATE
config_target
plugin_host_proto
gRPC::grpc++
protobuf::libprotobuf
libzmq
)
endfunction()

View File

@@ -1,649 +0,0 @@
// Generated by the gRPC C++ plugin.
// If you make any local change, they will be lost.
// source: daw_api.proto
#include "daw_api.pb.h"
#include "daw_api.grpc.pb.h"
#include <functional>
#include <grpcpp/support/async_stream.h>
#include <grpcpp/support/async_unary_call.h>
#include <grpcpp/impl/channel_interface.h>
#include <grpcpp/impl/client_unary_call.h>
#include <grpcpp/support/client_callback.h>
#include <grpcpp/support/message_allocator.h>
#include <grpcpp/support/method_handler.h>
#include <grpcpp/impl/rpc_service_method.h>
#include <grpcpp/support/server_callback.h>
#include <grpcpp/impl/server_callback_handlers.h>
#include <grpcpp/server_context.h>
#include <grpcpp/impl/service_type.h>
#include <grpcpp/support/sync_stream.h>
namespace daw {
namespace api {
static const char* TransportService_method_names[] = {
"/daw.api.TransportService/Play",
"/daw.api.TransportService/Pause",
"/daw.api.TransportService/Stop",
"/daw.api.TransportService/SetTempo",
};
std::unique_ptr< TransportService::Stub> TransportService::NewStub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options) {
(void)options;
std::unique_ptr< TransportService::Stub> stub(new TransportService::Stub(channel, options));
return stub;
}
TransportService::Stub::Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options)
: channel_(channel), rpcmethod_Play_(TransportService_method_names[0], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
, rpcmethod_Pause_(TransportService_method_names[1], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
, rpcmethod_Stop_(TransportService_method_names[2], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
, rpcmethod_SetTempo_(TransportService_method_names[3], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
{}
::grpc::Status TransportService::Stub::Play(::grpc::ClientContext* context, const ::daw::api::Empty& request, ::daw::api::StatusResponse* response) {
return ::grpc::internal::BlockingUnaryCall< ::daw::api::Empty, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_Play_, context, request, response);
}
void TransportService::Stub::async::Play(::grpc::ClientContext* context, const ::daw::api::Empty* request, ::daw::api::StatusResponse* response, std::function<void(::grpc::Status)> f) {
::grpc::internal::CallbackUnaryCall< ::daw::api::Empty, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_Play_, context, request, response, std::move(f));
}
void TransportService::Stub::async::Play(::grpc::ClientContext* context, const ::daw::api::Empty* request, ::daw::api::StatusResponse* response, ::grpc::ClientUnaryReactor* reactor) {
::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_Play_, context, request, response, reactor);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* TransportService::Stub::PrepareAsyncPlayRaw(::grpc::ClientContext* context, const ::daw::api::Empty& request, ::grpc::CompletionQueue* cq) {
return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::daw::api::StatusResponse, ::daw::api::Empty, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_Play_, context, request);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* TransportService::Stub::AsyncPlayRaw(::grpc::ClientContext* context, const ::daw::api::Empty& request, ::grpc::CompletionQueue* cq) {
auto* result =
this->PrepareAsyncPlayRaw(context, request, cq);
result->StartCall();
return result;
}
::grpc::Status TransportService::Stub::Pause(::grpc::ClientContext* context, const ::daw::api::Empty& request, ::daw::api::StatusResponse* response) {
return ::grpc::internal::BlockingUnaryCall< ::daw::api::Empty, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_Pause_, context, request, response);
}
void TransportService::Stub::async::Pause(::grpc::ClientContext* context, const ::daw::api::Empty* request, ::daw::api::StatusResponse* response, std::function<void(::grpc::Status)> f) {
::grpc::internal::CallbackUnaryCall< ::daw::api::Empty, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_Pause_, context, request, response, std::move(f));
}
void TransportService::Stub::async::Pause(::grpc::ClientContext* context, const ::daw::api::Empty* request, ::daw::api::StatusResponse* response, ::grpc::ClientUnaryReactor* reactor) {
::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_Pause_, context, request, response, reactor);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* TransportService::Stub::PrepareAsyncPauseRaw(::grpc::ClientContext* context, const ::daw::api::Empty& request, ::grpc::CompletionQueue* cq) {
return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::daw::api::StatusResponse, ::daw::api::Empty, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_Pause_, context, request);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* TransportService::Stub::AsyncPauseRaw(::grpc::ClientContext* context, const ::daw::api::Empty& request, ::grpc::CompletionQueue* cq) {
auto* result =
this->PrepareAsyncPauseRaw(context, request, cq);
result->StartCall();
return result;
}
::grpc::Status TransportService::Stub::Stop(::grpc::ClientContext* context, const ::daw::api::Empty& request, ::daw::api::StatusResponse* response) {
return ::grpc::internal::BlockingUnaryCall< ::daw::api::Empty, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_Stop_, context, request, response);
}
void TransportService::Stub::async::Stop(::grpc::ClientContext* context, const ::daw::api::Empty* request, ::daw::api::StatusResponse* response, std::function<void(::grpc::Status)> f) {
::grpc::internal::CallbackUnaryCall< ::daw::api::Empty, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_Stop_, context, request, response, std::move(f));
}
void TransportService::Stub::async::Stop(::grpc::ClientContext* context, const ::daw::api::Empty* request, ::daw::api::StatusResponse* response, ::grpc::ClientUnaryReactor* reactor) {
::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_Stop_, context, request, response, reactor);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* TransportService::Stub::PrepareAsyncStopRaw(::grpc::ClientContext* context, const ::daw::api::Empty& request, ::grpc::CompletionQueue* cq) {
return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::daw::api::StatusResponse, ::daw::api::Empty, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_Stop_, context, request);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* TransportService::Stub::AsyncStopRaw(::grpc::ClientContext* context, const ::daw::api::Empty& request, ::grpc::CompletionQueue* cq) {
auto* result =
this->PrepareAsyncStopRaw(context, request, cq);
result->StartCall();
return result;
}
::grpc::Status TransportService::Stub::SetTempo(::grpc::ClientContext* context, const ::daw::api::SetTempoRequest& request, ::daw::api::StatusResponse* response) {
return ::grpc::internal::BlockingUnaryCall< ::daw::api::SetTempoRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_SetTempo_, context, request, response);
}
void TransportService::Stub::async::SetTempo(::grpc::ClientContext* context, const ::daw::api::SetTempoRequest* request, ::daw::api::StatusResponse* response, std::function<void(::grpc::Status)> f) {
::grpc::internal::CallbackUnaryCall< ::daw::api::SetTempoRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_SetTempo_, context, request, response, std::move(f));
}
void TransportService::Stub::async::SetTempo(::grpc::ClientContext* context, const ::daw::api::SetTempoRequest* request, ::daw::api::StatusResponse* response, ::grpc::ClientUnaryReactor* reactor) {
::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_SetTempo_, context, request, response, reactor);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* TransportService::Stub::PrepareAsyncSetTempoRaw(::grpc::ClientContext* context, const ::daw::api::SetTempoRequest& request, ::grpc::CompletionQueue* cq) {
return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::daw::api::StatusResponse, ::daw::api::SetTempoRequest, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_SetTempo_, context, request);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* TransportService::Stub::AsyncSetTempoRaw(::grpc::ClientContext* context, const ::daw::api::SetTempoRequest& request, ::grpc::CompletionQueue* cq) {
auto* result =
this->PrepareAsyncSetTempoRaw(context, request, cq);
result->StartCall();
return result;
}
TransportService::Service::Service() {
AddMethod(new ::grpc::internal::RpcServiceMethod(
TransportService_method_names[0],
::grpc::internal::RpcMethod::NORMAL_RPC,
new ::grpc::internal::RpcMethodHandler< TransportService::Service, ::daw::api::Empty, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
[](TransportService::Service* service,
::grpc::ServerContext* ctx,
const ::daw::api::Empty* req,
::daw::api::StatusResponse* resp) {
return service->Play(ctx, req, resp);
}, this)));
AddMethod(new ::grpc::internal::RpcServiceMethod(
TransportService_method_names[1],
::grpc::internal::RpcMethod::NORMAL_RPC,
new ::grpc::internal::RpcMethodHandler< TransportService::Service, ::daw::api::Empty, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
[](TransportService::Service* service,
::grpc::ServerContext* ctx,
const ::daw::api::Empty* req,
::daw::api::StatusResponse* resp) {
return service->Pause(ctx, req, resp);
}, this)));
AddMethod(new ::grpc::internal::RpcServiceMethod(
TransportService_method_names[2],
::grpc::internal::RpcMethod::NORMAL_RPC,
new ::grpc::internal::RpcMethodHandler< TransportService::Service, ::daw::api::Empty, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
[](TransportService::Service* service,
::grpc::ServerContext* ctx,
const ::daw::api::Empty* req,
::daw::api::StatusResponse* resp) {
return service->Stop(ctx, req, resp);
}, this)));
AddMethod(new ::grpc::internal::RpcServiceMethod(
TransportService_method_names[3],
::grpc::internal::RpcMethod::NORMAL_RPC,
new ::grpc::internal::RpcMethodHandler< TransportService::Service, ::daw::api::SetTempoRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
[](TransportService::Service* service,
::grpc::ServerContext* ctx,
const ::daw::api::SetTempoRequest* req,
::daw::api::StatusResponse* resp) {
return service->SetTempo(ctx, req, resp);
}, this)));
}
TransportService::Service::~Service() {
}
::grpc::Status TransportService::Service::Play(::grpc::ServerContext* context, const ::daw::api::Empty* request, ::daw::api::StatusResponse* response) {
(void) context;
(void) request;
(void) response;
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
::grpc::Status TransportService::Service::Pause(::grpc::ServerContext* context, const ::daw::api::Empty* request, ::daw::api::StatusResponse* response) {
(void) context;
(void) request;
(void) response;
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
::grpc::Status TransportService::Service::Stop(::grpc::ServerContext* context, const ::daw::api::Empty* request, ::daw::api::StatusResponse* response) {
(void) context;
(void) request;
(void) response;
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
::grpc::Status TransportService::Service::SetTempo(::grpc::ServerContext* context, const ::daw::api::SetTempoRequest* request, ::daw::api::StatusResponse* response) {
(void) context;
(void) request;
(void) response;
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
static const char* ProjectService_method_names[] = {
"/daw.api.ProjectService/NewProject",
"/daw.api.ProjectService/LoadProject",
"/daw.api.ProjectService/SaveProject",
};
std::unique_ptr< ProjectService::Stub> ProjectService::NewStub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options) {
(void)options;
std::unique_ptr< ProjectService::Stub> stub(new ProjectService::Stub(channel, options));
return stub;
}
ProjectService::Stub::Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options)
: channel_(channel), rpcmethod_NewProject_(ProjectService_method_names[0], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
, rpcmethod_LoadProject_(ProjectService_method_names[1], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
, rpcmethod_SaveProject_(ProjectService_method_names[2], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
{}
::grpc::Status ProjectService::Stub::NewProject(::grpc::ClientContext* context, const ::daw::api::Empty& request, ::daw::api::ProjectState* response) {
return ::grpc::internal::BlockingUnaryCall< ::daw::api::Empty, ::daw::api::ProjectState, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_NewProject_, context, request, response);
}
void ProjectService::Stub::async::NewProject(::grpc::ClientContext* context, const ::daw::api::Empty* request, ::daw::api::ProjectState* response, std::function<void(::grpc::Status)> f) {
::grpc::internal::CallbackUnaryCall< ::daw::api::Empty, ::daw::api::ProjectState, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_NewProject_, context, request, response, std::move(f));
}
void ProjectService::Stub::async::NewProject(::grpc::ClientContext* context, const ::daw::api::Empty* request, ::daw::api::ProjectState* response, ::grpc::ClientUnaryReactor* reactor) {
::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_NewProject_, context, request, response, reactor);
}
::grpc::ClientAsyncResponseReader< ::daw::api::ProjectState>* ProjectService::Stub::PrepareAsyncNewProjectRaw(::grpc::ClientContext* context, const ::daw::api::Empty& request, ::grpc::CompletionQueue* cq) {
return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::daw::api::ProjectState, ::daw::api::Empty, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_NewProject_, context, request);
}
::grpc::ClientAsyncResponseReader< ::daw::api::ProjectState>* ProjectService::Stub::AsyncNewProjectRaw(::grpc::ClientContext* context, const ::daw::api::Empty& request, ::grpc::CompletionQueue* cq) {
auto* result =
this->PrepareAsyncNewProjectRaw(context, request, cq);
result->StartCall();
return result;
}
::grpc::Status ProjectService::Stub::LoadProject(::grpc::ClientContext* context, const ::daw::api::LoadProjectRequest& request, ::daw::api::ProjectState* response) {
return ::grpc::internal::BlockingUnaryCall< ::daw::api::LoadProjectRequest, ::daw::api::ProjectState, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_LoadProject_, context, request, response);
}
void ProjectService::Stub::async::LoadProject(::grpc::ClientContext* context, const ::daw::api::LoadProjectRequest* request, ::daw::api::ProjectState* response, std::function<void(::grpc::Status)> f) {
::grpc::internal::CallbackUnaryCall< ::daw::api::LoadProjectRequest, ::daw::api::ProjectState, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_LoadProject_, context, request, response, std::move(f));
}
void ProjectService::Stub::async::LoadProject(::grpc::ClientContext* context, const ::daw::api::LoadProjectRequest* request, ::daw::api::ProjectState* response, ::grpc::ClientUnaryReactor* reactor) {
::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_LoadProject_, context, request, response, reactor);
}
::grpc::ClientAsyncResponseReader< ::daw::api::ProjectState>* ProjectService::Stub::PrepareAsyncLoadProjectRaw(::grpc::ClientContext* context, const ::daw::api::LoadProjectRequest& request, ::grpc::CompletionQueue* cq) {
return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::daw::api::ProjectState, ::daw::api::LoadProjectRequest, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_LoadProject_, context, request);
}
::grpc::ClientAsyncResponseReader< ::daw::api::ProjectState>* ProjectService::Stub::AsyncLoadProjectRaw(::grpc::ClientContext* context, const ::daw::api::LoadProjectRequest& request, ::grpc::CompletionQueue* cq) {
auto* result =
this->PrepareAsyncLoadProjectRaw(context, request, cq);
result->StartCall();
return result;
}
::grpc::Status ProjectService::Stub::SaveProject(::grpc::ClientContext* context, const ::daw::api::SaveProjectRequest& request, ::daw::api::StatusResponse* response) {
return ::grpc::internal::BlockingUnaryCall< ::daw::api::SaveProjectRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_SaveProject_, context, request, response);
}
void ProjectService::Stub::async::SaveProject(::grpc::ClientContext* context, const ::daw::api::SaveProjectRequest* request, ::daw::api::StatusResponse* response, std::function<void(::grpc::Status)> f) {
::grpc::internal::CallbackUnaryCall< ::daw::api::SaveProjectRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_SaveProject_, context, request, response, std::move(f));
}
void ProjectService::Stub::async::SaveProject(::grpc::ClientContext* context, const ::daw::api::SaveProjectRequest* request, ::daw::api::StatusResponse* response, ::grpc::ClientUnaryReactor* reactor) {
::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_SaveProject_, context, request, response, reactor);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* ProjectService::Stub::PrepareAsyncSaveProjectRaw(::grpc::ClientContext* context, const ::daw::api::SaveProjectRequest& request, ::grpc::CompletionQueue* cq) {
return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::daw::api::StatusResponse, ::daw::api::SaveProjectRequest, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_SaveProject_, context, request);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* ProjectService::Stub::AsyncSaveProjectRaw(::grpc::ClientContext* context, const ::daw::api::SaveProjectRequest& request, ::grpc::CompletionQueue* cq) {
auto* result =
this->PrepareAsyncSaveProjectRaw(context, request, cq);
result->StartCall();
return result;
}
ProjectService::Service::Service() {
AddMethod(new ::grpc::internal::RpcServiceMethod(
ProjectService_method_names[0],
::grpc::internal::RpcMethod::NORMAL_RPC,
new ::grpc::internal::RpcMethodHandler< ProjectService::Service, ::daw::api::Empty, ::daw::api::ProjectState, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
[](ProjectService::Service* service,
::grpc::ServerContext* ctx,
const ::daw::api::Empty* req,
::daw::api::ProjectState* resp) {
return service->NewProject(ctx, req, resp);
}, this)));
AddMethod(new ::grpc::internal::RpcServiceMethod(
ProjectService_method_names[1],
::grpc::internal::RpcMethod::NORMAL_RPC,
new ::grpc::internal::RpcMethodHandler< ProjectService::Service, ::daw::api::LoadProjectRequest, ::daw::api::ProjectState, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
[](ProjectService::Service* service,
::grpc::ServerContext* ctx,
const ::daw::api::LoadProjectRequest* req,
::daw::api::ProjectState* resp) {
return service->LoadProject(ctx, req, resp);
}, this)));
AddMethod(new ::grpc::internal::RpcServiceMethod(
ProjectService_method_names[2],
::grpc::internal::RpcMethod::NORMAL_RPC,
new ::grpc::internal::RpcMethodHandler< ProjectService::Service, ::daw::api::SaveProjectRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
[](ProjectService::Service* service,
::grpc::ServerContext* ctx,
const ::daw::api::SaveProjectRequest* req,
::daw::api::StatusResponse* resp) {
return service->SaveProject(ctx, req, resp);
}, this)));
}
ProjectService::Service::~Service() {
}
::grpc::Status ProjectService::Service::NewProject(::grpc::ServerContext* context, const ::daw::api::Empty* request, ::daw::api::ProjectState* response) {
(void) context;
(void) request;
(void) response;
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
::grpc::Status ProjectService::Service::LoadProject(::grpc::ServerContext* context, const ::daw::api::LoadProjectRequest* request, ::daw::api::ProjectState* response) {
(void) context;
(void) request;
(void) response;
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
::grpc::Status ProjectService::Service::SaveProject(::grpc::ServerContext* context, const ::daw::api::SaveProjectRequest* request, ::daw::api::StatusResponse* response) {
(void) context;
(void) request;
(void) response;
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
static const char* TrackService_method_names[] = {
"/daw.api.TrackService/AddTrack",
"/daw.api.TrackService/RemoveTrack",
"/daw.api.TrackService/SetTrackVolume",
"/daw.api.TrackService/SetTrackPan",
};
std::unique_ptr< TrackService::Stub> TrackService::NewStub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options) {
(void)options;
std::unique_ptr< TrackService::Stub> stub(new TrackService::Stub(channel, options));
return stub;
}
TrackService::Stub::Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options)
: channel_(channel), rpcmethod_AddTrack_(TrackService_method_names[0], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
, rpcmethod_RemoveTrack_(TrackService_method_names[1], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
, rpcmethod_SetTrackVolume_(TrackService_method_names[2], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
, rpcmethod_SetTrackPan_(TrackService_method_names[3], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
{}
::grpc::Status TrackService::Stub::AddTrack(::grpc::ClientContext* context, const ::daw::api::AddTrackRequest& request, ::daw::api::TrackInfo* response) {
return ::grpc::internal::BlockingUnaryCall< ::daw::api::AddTrackRequest, ::daw::api::TrackInfo, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_AddTrack_, context, request, response);
}
void TrackService::Stub::async::AddTrack(::grpc::ClientContext* context, const ::daw::api::AddTrackRequest* request, ::daw::api::TrackInfo* response, std::function<void(::grpc::Status)> f) {
::grpc::internal::CallbackUnaryCall< ::daw::api::AddTrackRequest, ::daw::api::TrackInfo, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_AddTrack_, context, request, response, std::move(f));
}
void TrackService::Stub::async::AddTrack(::grpc::ClientContext* context, const ::daw::api::AddTrackRequest* request, ::daw::api::TrackInfo* response, ::grpc::ClientUnaryReactor* reactor) {
::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_AddTrack_, context, request, response, reactor);
}
::grpc::ClientAsyncResponseReader< ::daw::api::TrackInfo>* TrackService::Stub::PrepareAsyncAddTrackRaw(::grpc::ClientContext* context, const ::daw::api::AddTrackRequest& request, ::grpc::CompletionQueue* cq) {
return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::daw::api::TrackInfo, ::daw::api::AddTrackRequest, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_AddTrack_, context, request);
}
::grpc::ClientAsyncResponseReader< ::daw::api::TrackInfo>* TrackService::Stub::AsyncAddTrackRaw(::grpc::ClientContext* context, const ::daw::api::AddTrackRequest& request, ::grpc::CompletionQueue* cq) {
auto* result =
this->PrepareAsyncAddTrackRaw(context, request, cq);
result->StartCall();
return result;
}
::grpc::Status TrackService::Stub::RemoveTrack(::grpc::ClientContext* context, const ::daw::api::TrackIdRequest& request, ::daw::api::StatusResponse* response) {
return ::grpc::internal::BlockingUnaryCall< ::daw::api::TrackIdRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_RemoveTrack_, context, request, response);
}
void TrackService::Stub::async::RemoveTrack(::grpc::ClientContext* context, const ::daw::api::TrackIdRequest* request, ::daw::api::StatusResponse* response, std::function<void(::grpc::Status)> f) {
::grpc::internal::CallbackUnaryCall< ::daw::api::TrackIdRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_RemoveTrack_, context, request, response, std::move(f));
}
void TrackService::Stub::async::RemoveTrack(::grpc::ClientContext* context, const ::daw::api::TrackIdRequest* request, ::daw::api::StatusResponse* response, ::grpc::ClientUnaryReactor* reactor) {
::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_RemoveTrack_, context, request, response, reactor);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* TrackService::Stub::PrepareAsyncRemoveTrackRaw(::grpc::ClientContext* context, const ::daw::api::TrackIdRequest& request, ::grpc::CompletionQueue* cq) {
return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::daw::api::StatusResponse, ::daw::api::TrackIdRequest, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_RemoveTrack_, context, request);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* TrackService::Stub::AsyncRemoveTrackRaw(::grpc::ClientContext* context, const ::daw::api::TrackIdRequest& request, ::grpc::CompletionQueue* cq) {
auto* result =
this->PrepareAsyncRemoveTrackRaw(context, request, cq);
result->StartCall();
return result;
}
::grpc::Status TrackService::Stub::SetTrackVolume(::grpc::ClientContext* context, const ::daw::api::SetTrackVolumeRequest& request, ::daw::api::StatusResponse* response) {
return ::grpc::internal::BlockingUnaryCall< ::daw::api::SetTrackVolumeRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_SetTrackVolume_, context, request, response);
}
void TrackService::Stub::async::SetTrackVolume(::grpc::ClientContext* context, const ::daw::api::SetTrackVolumeRequest* request, ::daw::api::StatusResponse* response, std::function<void(::grpc::Status)> f) {
::grpc::internal::CallbackUnaryCall< ::daw::api::SetTrackVolumeRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_SetTrackVolume_, context, request, response, std::move(f));
}
void TrackService::Stub::async::SetTrackVolume(::grpc::ClientContext* context, const ::daw::api::SetTrackVolumeRequest* request, ::daw::api::StatusResponse* response, ::grpc::ClientUnaryReactor* reactor) {
::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_SetTrackVolume_, context, request, response, reactor);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* TrackService::Stub::PrepareAsyncSetTrackVolumeRaw(::grpc::ClientContext* context, const ::daw::api::SetTrackVolumeRequest& request, ::grpc::CompletionQueue* cq) {
return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::daw::api::StatusResponse, ::daw::api::SetTrackVolumeRequest, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_SetTrackVolume_, context, request);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* TrackService::Stub::AsyncSetTrackVolumeRaw(::grpc::ClientContext* context, const ::daw::api::SetTrackVolumeRequest& request, ::grpc::CompletionQueue* cq) {
auto* result =
this->PrepareAsyncSetTrackVolumeRaw(context, request, cq);
result->StartCall();
return result;
}
::grpc::Status TrackService::Stub::SetTrackPan(::grpc::ClientContext* context, const ::daw::api::SetTrackPanRequest& request, ::daw::api::StatusResponse* response) {
return ::grpc::internal::BlockingUnaryCall< ::daw::api::SetTrackPanRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_SetTrackPan_, context, request, response);
}
void TrackService::Stub::async::SetTrackPan(::grpc::ClientContext* context, const ::daw::api::SetTrackPanRequest* request, ::daw::api::StatusResponse* response, std::function<void(::grpc::Status)> f) {
::grpc::internal::CallbackUnaryCall< ::daw::api::SetTrackPanRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_SetTrackPan_, context, request, response, std::move(f));
}
void TrackService::Stub::async::SetTrackPan(::grpc::ClientContext* context, const ::daw::api::SetTrackPanRequest* request, ::daw::api::StatusResponse* response, ::grpc::ClientUnaryReactor* reactor) {
::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_SetTrackPan_, context, request, response, reactor);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* TrackService::Stub::PrepareAsyncSetTrackPanRaw(::grpc::ClientContext* context, const ::daw::api::SetTrackPanRequest& request, ::grpc::CompletionQueue* cq) {
return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::daw::api::StatusResponse, ::daw::api::SetTrackPanRequest, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_SetTrackPan_, context, request);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* TrackService::Stub::AsyncSetTrackPanRaw(::grpc::ClientContext* context, const ::daw::api::SetTrackPanRequest& request, ::grpc::CompletionQueue* cq) {
auto* result =
this->PrepareAsyncSetTrackPanRaw(context, request, cq);
result->StartCall();
return result;
}
TrackService::Service::Service() {
AddMethod(new ::grpc::internal::RpcServiceMethod(
TrackService_method_names[0],
::grpc::internal::RpcMethod::NORMAL_RPC,
new ::grpc::internal::RpcMethodHandler< TrackService::Service, ::daw::api::AddTrackRequest, ::daw::api::TrackInfo, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
[](TrackService::Service* service,
::grpc::ServerContext* ctx,
const ::daw::api::AddTrackRequest* req,
::daw::api::TrackInfo* resp) {
return service->AddTrack(ctx, req, resp);
}, this)));
AddMethod(new ::grpc::internal::RpcServiceMethod(
TrackService_method_names[1],
::grpc::internal::RpcMethod::NORMAL_RPC,
new ::grpc::internal::RpcMethodHandler< TrackService::Service, ::daw::api::TrackIdRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
[](TrackService::Service* service,
::grpc::ServerContext* ctx,
const ::daw::api::TrackIdRequest* req,
::daw::api::StatusResponse* resp) {
return service->RemoveTrack(ctx, req, resp);
}, this)));
AddMethod(new ::grpc::internal::RpcServiceMethod(
TrackService_method_names[2],
::grpc::internal::RpcMethod::NORMAL_RPC,
new ::grpc::internal::RpcMethodHandler< TrackService::Service, ::daw::api::SetTrackVolumeRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
[](TrackService::Service* service,
::grpc::ServerContext* ctx,
const ::daw::api::SetTrackVolumeRequest* req,
::daw::api::StatusResponse* resp) {
return service->SetTrackVolume(ctx, req, resp);
}, this)));
AddMethod(new ::grpc::internal::RpcServiceMethod(
TrackService_method_names[3],
::grpc::internal::RpcMethod::NORMAL_RPC,
new ::grpc::internal::RpcMethodHandler< TrackService::Service, ::daw::api::SetTrackPanRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
[](TrackService::Service* service,
::grpc::ServerContext* ctx,
const ::daw::api::SetTrackPanRequest* req,
::daw::api::StatusResponse* resp) {
return service->SetTrackPan(ctx, req, resp);
}, this)));
}
TrackService::Service::~Service() {
}
::grpc::Status TrackService::Service::AddTrack(::grpc::ServerContext* context, const ::daw::api::AddTrackRequest* request, ::daw::api::TrackInfo* response) {
(void) context;
(void) request;
(void) response;
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
::grpc::Status TrackService::Service::RemoveTrack(::grpc::ServerContext* context, const ::daw::api::TrackIdRequest* request, ::daw::api::StatusResponse* response) {
(void) context;
(void) request;
(void) response;
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
::grpc::Status TrackService::Service::SetTrackVolume(::grpc::ServerContext* context, const ::daw::api::SetTrackVolumeRequest* request, ::daw::api::StatusResponse* response) {
(void) context;
(void) request;
(void) response;
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
::grpc::Status TrackService::Service::SetTrackPan(::grpc::ServerContext* context, const ::daw::api::SetTrackPanRequest* request, ::daw::api::StatusResponse* response) {
(void) context;
(void) request;
(void) response;
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
static const char* PluginService_method_names[] = {
"/daw.api.PluginService/LoadPlugin",
"/daw.api.PluginService/SetPluginParameter",
};
std::unique_ptr< PluginService::Stub> PluginService::NewStub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options) {
(void)options;
std::unique_ptr< PluginService::Stub> stub(new PluginService::Stub(channel, options));
return stub;
}
PluginService::Stub::Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options)
: channel_(channel), rpcmethod_LoadPlugin_(PluginService_method_names[0], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
, rpcmethod_SetPluginParameter_(PluginService_method_names[1], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
{}
::grpc::Status PluginService::Stub::LoadPlugin(::grpc::ClientContext* context, const ::daw::api::LoadPluginRequest& request, ::daw::api::PluginInfo* response) {
return ::grpc::internal::BlockingUnaryCall< ::daw::api::LoadPluginRequest, ::daw::api::PluginInfo, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_LoadPlugin_, context, request, response);
}
void PluginService::Stub::async::LoadPlugin(::grpc::ClientContext* context, const ::daw::api::LoadPluginRequest* request, ::daw::api::PluginInfo* response, std::function<void(::grpc::Status)> f) {
::grpc::internal::CallbackUnaryCall< ::daw::api::LoadPluginRequest, ::daw::api::PluginInfo, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_LoadPlugin_, context, request, response, std::move(f));
}
void PluginService::Stub::async::LoadPlugin(::grpc::ClientContext* context, const ::daw::api::LoadPluginRequest* request, ::daw::api::PluginInfo* response, ::grpc::ClientUnaryReactor* reactor) {
::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_LoadPlugin_, context, request, response, reactor);
}
::grpc::ClientAsyncResponseReader< ::daw::api::PluginInfo>* PluginService::Stub::PrepareAsyncLoadPluginRaw(::grpc::ClientContext* context, const ::daw::api::LoadPluginRequest& request, ::grpc::CompletionQueue* cq) {
return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::daw::api::PluginInfo, ::daw::api::LoadPluginRequest, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_LoadPlugin_, context, request);
}
::grpc::ClientAsyncResponseReader< ::daw::api::PluginInfo>* PluginService::Stub::AsyncLoadPluginRaw(::grpc::ClientContext* context, const ::daw::api::LoadPluginRequest& request, ::grpc::CompletionQueue* cq) {
auto* result =
this->PrepareAsyncLoadPluginRaw(context, request, cq);
result->StartCall();
return result;
}
::grpc::Status PluginService::Stub::SetPluginParameter(::grpc::ClientContext* context, const ::daw::api::SetPluginParameterRequest& request, ::daw::api::StatusResponse* response) {
return ::grpc::internal::BlockingUnaryCall< ::daw::api::SetPluginParameterRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_SetPluginParameter_, context, request, response);
}
void PluginService::Stub::async::SetPluginParameter(::grpc::ClientContext* context, const ::daw::api::SetPluginParameterRequest* request, ::daw::api::StatusResponse* response, std::function<void(::grpc::Status)> f) {
::grpc::internal::CallbackUnaryCall< ::daw::api::SetPluginParameterRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_SetPluginParameter_, context, request, response, std::move(f));
}
void PluginService::Stub::async::SetPluginParameter(::grpc::ClientContext* context, const ::daw::api::SetPluginParameterRequest* request, ::daw::api::StatusResponse* response, ::grpc::ClientUnaryReactor* reactor) {
::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_SetPluginParameter_, context, request, response, reactor);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* PluginService::Stub::PrepareAsyncSetPluginParameterRaw(::grpc::ClientContext* context, const ::daw::api::SetPluginParameterRequest& request, ::grpc::CompletionQueue* cq) {
return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::daw::api::StatusResponse, ::daw::api::SetPluginParameterRequest, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_SetPluginParameter_, context, request);
}
::grpc::ClientAsyncResponseReader< ::daw::api::StatusResponse>* PluginService::Stub::AsyncSetPluginParameterRaw(::grpc::ClientContext* context, const ::daw::api::SetPluginParameterRequest& request, ::grpc::CompletionQueue* cq) {
auto* result =
this->PrepareAsyncSetPluginParameterRaw(context, request, cq);
result->StartCall();
return result;
}
PluginService::Service::Service() {
AddMethod(new ::grpc::internal::RpcServiceMethod(
PluginService_method_names[0],
::grpc::internal::RpcMethod::NORMAL_RPC,
new ::grpc::internal::RpcMethodHandler< PluginService::Service, ::daw::api::LoadPluginRequest, ::daw::api::PluginInfo, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
[](PluginService::Service* service,
::grpc::ServerContext* ctx,
const ::daw::api::LoadPluginRequest* req,
::daw::api::PluginInfo* resp) {
return service->LoadPlugin(ctx, req, resp);
}, this)));
AddMethod(new ::grpc::internal::RpcServiceMethod(
PluginService_method_names[1],
::grpc::internal::RpcMethod::NORMAL_RPC,
new ::grpc::internal::RpcMethodHandler< PluginService::Service, ::daw::api::SetPluginParameterRequest, ::daw::api::StatusResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
[](PluginService::Service* service,
::grpc::ServerContext* ctx,
const ::daw::api::SetPluginParameterRequest* req,
::daw::api::StatusResponse* resp) {
return service->SetPluginParameter(ctx, req, resp);
}, this)));
}
PluginService::Service::~Service() {
}
::grpc::Status PluginService::Service::LoadPlugin(::grpc::ServerContext* context, const ::daw::api::LoadPluginRequest* request, ::daw::api::PluginInfo* response) {
(void) context;
(void) request;
(void) response;
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
::grpc::Status PluginService::Service::SetPluginParameter(::grpc::ServerContext* context, const ::daw::api::SetPluginParameterRequest* request, ::daw::api::StatusResponse* response) {
(void) context;
(void) request;
(void) response;
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
} // namespace daw
} // namespace api

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -1,3 +0,0 @@
//
// Created by A on 2025/8/13.
//

View File

@@ -1,10 +0,0 @@
{
"dependencies": [
"grpc",
"protobuf",
"cppzmq",
"gtest"
],
"version": "0.0.1",
"name": "ninaengine"
}