nx_server_plugin_sdk 1.0 Server Plugin SDK

engine.h
1 // Copyright 2018-present Network Optix, Inc. Licensed under MPL 2.0: www.mozilla.org/MPL/2.0/
2
3 #pragma once
4
5 #include <nx/sdk/analytics/helpers/engine.h>
6
7 namespace nx {
8 namespace vms_server_plugins {
9 namespace analytics {
10 namespace stub {
11 namespace object_actions {
12
13 class Engine: public nx::sdk::analytics::Engine
14 {
15 public:
16 Engine();
17 virtual ~Engine() override;
18
19 protected:
20 virtual std::string manifestString() const override;
21
22 protected:
23 virtual void doObtainDeviceAgent(
24 nx::sdk::Result<nx::sdk::analytics::IDeviceAgent*>* outResult,
25 const nx::sdk::IDeviceInfo* deviceInfo) override;
26
27 virtual nx::sdk::Result<sdk::analytics::IAction::Result> executeAction(
28 const std::string& actionId,
29 nx::sdk::Uuid trackId,
30 nx::sdk::Uuid deviceId,
31 int64_t timestampUs,
32 nx::sdk::Ptr<nx::sdk::analytics::IObjectTrackInfo> objectTrackInfo,
33 const std::map<std::string, std::string>& params) override;
34
35 private:
36 nx::sdk::Result<sdk::analytics::IAction::Result> executeActionWithMessageResult(
37 nx::sdk::Uuid trackId,
38 nx::sdk::Uuid deviceId,
39 int64_t timestampUs,
40 nx::sdk::Ptr<nx::sdk::analytics::IObjectTrackInfo> objectTrackInfo);
41
42 nx::sdk::Result<sdk::analytics::IAction::Result> executeActionWithUrlResult();
43
44 nx::sdk::Result<sdk::analytics::IAction::Result> executeActionWithParameters(
45 nx::sdk::Uuid trackId,
46 nx::sdk::Uuid deviceId,
47 int64_t timestampUs,
48 nx::sdk::Ptr<nx::sdk::analytics::IObjectTrackInfo> objectTrackInfo,
49 const std::map<std::string, std::string>& params);
50
51 nx::sdk::Result<sdk::analytics::IAction::Result> executeActionWithRequirements(
52 nx::sdk::Uuid trackId,
53 nx::sdk::Uuid deviceId,
54 int64_t timestampUs,
55 nx::sdk::Ptr<nx::sdk::analytics::IObjectTrackInfo> objectTrackInfo);
56 };
57
58 } // namespace object_actions
59 } // namespace stub
60 } // namespace analytics
61 } // namespace vms_server_plugins
62 } // namespace nx
nx::sdk::Ptr
Definition: ptr.h:18
nx::vms_server_plugins::analytics::stub::object_actions::Engine::executeAction
virtual nx::sdk::Result< sdk::analytics::IAction::Result > executeAction(const std::string &actionId, nx::sdk::Uuid trackId, nx::sdk::Uuid deviceId, int64_t timestampUs, nx::sdk::Ptr< nx::sdk::analytics::IObjectTrackInfo > objectTrackInfo, const std::map< std::string, std::string > &params) override
Definition: engine.cpp:239
nx::sdk::Uuid
Definition: uuid.h:22
nx::sdk::IDeviceInfo
Definition: i_device_info.h:13
nx::sdk::Result
Definition: result.h:52
nx
Definition: apple_utils.h:6
nx::vms_server_plugins::analytics::stub::object_actions::Engine
Definition: engine.h:13
nx::sdk::analytics::Engine
Definition: engine.h:31