nx_metadata_sdk 1.0 Metadata SDK

i_plugin.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/interface.h>
6
7 namespace nx::sdk {
8
9 class IUtilityProvider;
10
26 class IPlugin: public Interface<IPlugin>
27 {
28 public:
29 static auto interfaceId()
30 {
31 return makeIdWithAlternative("nx::sdk::IPlugin",
32 /* Planned future renaming. */ "nx::sdk::IIntegration");
33 }
34
41 typedef IPlugin* (*EntryPointFunc)();
42
44 static constexpr const char* kEntryPointFuncName = "createNxPlugin";
45
56 typedef IPlugin* (*MultiEntryPointFunc)(int instanceIndex);
57
59 static constexpr const char* kMultiEntryPointFuncName = "createNxPluginByIndex";
60
67 virtual void setUtilityProvider(IUtilityProvider* utilityProvider) = 0;
68 };
69 using IPlugin0 = IPlugin;
70
71 } // namespace nx::sdk
nx::sdk::IPlugin::kMultiEntryPointFuncName
static constexpr const char * kMultiEntryPointFuncName
Definition: i_plugin.h:59
nx::sdk::Interface
Definition: interface.h:48
nx::sdk::IPlugin::kEntryPointFuncName
static constexpr const char * kEntryPointFuncName
Definition: i_plugin.h:44
nx::sdk::IPlugin::setUtilityProvider
virtual void setUtilityProvider(IUtilityProvider *utilityProvider)=0
nx::sdk::IPlugin
Definition: i_plugin.h:26
nx::sdk::IUtilityProvider
Definition: i_utility_provider.h:78
nx::sdk
Definition: device_agent.h:12
nx::sdk::IRefCountable::makeIdWithAlternative
static std::vector< const InterfaceId * > makeIdWithAlternative(const char(&charArray)[len], const char(&alternativeCharArray)[alternativeLen])
Definition: i_ref_countable.h:87