aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp/lwtrace/custom_action.cpp
diff options
context:
space:
mode:
authorserxa <serxa@yandex-team.ru>2022-02-10 16:49:08 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:49:08 +0300
commitd6d7db348c2cc64e71243cab9940ee6778f4317d (patch)
treebac67f42a02f9368eb4d329f5d79b77d0a6adc18 /library/cpp/lwtrace/custom_action.cpp
parent8d57b69dee81198a59c39e64704f7dc9f04b4fbf (diff)
downloadydb-d6d7db348c2cc64e71243cab9940ee6778f4317d.tar.gz
Restoring authorship annotation for <serxa@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'library/cpp/lwtrace/custom_action.cpp')
-rw-r--r--library/cpp/lwtrace/custom_action.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/library/cpp/lwtrace/custom_action.cpp b/library/cpp/lwtrace/custom_action.cpp
index a379b34ec0..dc97b44ac0 100644
--- a/library/cpp/lwtrace/custom_action.cpp
+++ b/library/cpp/lwtrace/custom_action.cpp
@@ -1,21 +1,21 @@
-#include "custom_action.h"
+#include "custom_action.h"
#include "control.h"
using namespace NLWTrace;
-TCustomActionExecutor* TCustomActionFactory::Create(TProbe* probe, const TCustomAction& action, TSession* trace) const {
- auto iter = Callbacks.find(action.GetName());
- if (iter != Callbacks.end()) {
- return iter->second(probe, action, trace);
- } else {
- return nullptr;
- }
+TCustomActionExecutor* TCustomActionFactory::Create(TProbe* probe, const TCustomAction& action, TSession* trace) const {
+ auto iter = Callbacks.find(action.GetName());
+ if (iter != Callbacks.end()) {
+ return iter->second(probe, action, trace);
+ } else {
+ return nullptr;
+ }
}
-
-void TCustomActionFactory::Register(const TString& name, const TCustomActionFactory::TCallback& callback) {
+
+void TCustomActionFactory::Register(const TString& name, const TCustomActionFactory::TCallback& callback) {
if (Callbacks.contains(name)) {
- ythrow yexception() << "duplicate custom action '" << name << "'";
- }
- Callbacks[name] = callback;
-}
+ ythrow yexception() << "duplicate custom action '" << name << "'";
+ }
+ Callbacks[name] = callback;
+}