Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: Pascal casing method name #233

Merged
merged 1 commit into from
Nov 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions languages/cpp/templates/methods/allowsFocus.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
JsonObject jsonParameters;
${method.params.serialization}

Firebolt::Error status = FireboltSDK::Async::Instance().Invoke<${method.result.json.type}>(_T("${info.title.lowercase}.${method.name}"), jsonParameters, ${method.name}AsyncResponseInnerCallback, reinterpret_cast<void*>(&response));
Firebolt::Error status = FireboltSDK::Async::Instance().Invoke<${method.result.json.type}>(_T("${info.title}.${method.name}"), jsonParameters, ${method.name}AsyncResponseInnerCallback, reinterpret_cast<void*>(&response));
if (status == Firebolt::Error::None) {
FIREBOLT_LOG_INFO(FireboltSDK::Logger::Category::OpenRPC, FireboltSDK::Logger::Module<FireboltSDK::Accessor>(), "${info.Title}.${method.name} is successfully invoked");
} else {
Expand All @@ -38,7 +38,7 @@
}
void ${info.Title}Impl::abort${method.Name}(I${info.Title}AsyncResponse& response, Firebolt::Error *err)
{
Firebolt::Error status = FireboltSDK::Async::Instance().Abort(_T("${info.title.lowercase}.${method.name}"), reinterpret_cast<void*>(&response));
Firebolt::Error status = FireboltSDK::Async::Instance().Abort(_T("${info.title}.${method.name}"), reinterpret_cast<void*>(&response));
if (err != nullptr) {
*err = status;
}
Expand Down
2 changes: 1 addition & 1 deletion languages/cpp/templates/methods/calls-metrics.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
JsonObject jsonParameters;
${method.params.serialization.with.indent}
${method.result.json.type} jsonResult;
status = transport->Invoke("${info.title.lowercase}.${method.name}", jsonParameters, jsonResult);
status = transport->Invoke("${info.title}.${method.name}", jsonParameters, jsonResult);
if (status == Firebolt::Error::None) {
FIREBOLT_LOG_INFO(FireboltSDK::Logger::Category::OpenRPC, FireboltSDK::Logger::Module<FireboltSDK::Accessor>(), "${info.Title}.${method.name} is successfully invoked");
${if.result.nonvoid}${method.result.instantiation.with.indent}${end.if.result.nonvoid}
Expand Down
2 changes: 1 addition & 1 deletion languages/cpp/templates/methods/default.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
JsonObject jsonParameters;
${method.params.serialization.with.indent}
${method.result.json.type} jsonResult;
statusError = transport->Invoke("${info.title.lowercase}.${method.name}", jsonParameters, jsonResult);
statusError = transport->Invoke("${info.title}.${method.name}", jsonParameters, jsonResult);
if (statusError == Firebolt::Error::None) {
FIREBOLT_LOG_INFO(FireboltSDK::Logger::Category::OpenRPC, FireboltSDK::Logger::Module<FireboltSDK::Accessor>(), "${info.Title}.${method.name} is successfully invoked");
${if.result.nonvoid}${method.result.instantiation.with.indent}${end.if.result.nonvoid}
Expand Down
4 changes: 2 additions & 2 deletions languages/cpp/templates/methods/event.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
}
void ${info.Title}Impl::globalSubscribe( I${info.Title}::I${method.Name}Notification& notification, Firebolt::Error *err )
{
const string eventName = _T("${info.title.lowercase}.${method.rpc.name}");
const string eventName = _T("${info.title}.${method.rpc.name}");
Firebolt::Error status = Firebolt::Error::None;

JsonObject jsonParameters;
Expand All @@ -66,7 +66,7 @@
}
void ${info.Title}Impl::globalUnsubscribe( I${info.Title}::I${method.Name}Notification& notification, Firebolt::Error *err )
{
Firebolt::Error status = FireboltSDK::Event::Instance().Unsubscribe(_T("${info.title.lowercase}.${method.rpc.name}"), reinterpret_cast<void*>(&notification));
Firebolt::Error status = FireboltSDK::Event::Instance().Unsubscribe(_T("${info.title}.${method.rpc.name}"), reinterpret_cast<void*>(&notification));

if (err != nullptr) {
*err = status;
Expand Down
Loading