1 // Copyright (C) 2018-2020 Intel Corporation
2 // SPDX-License-Identifier: Apache-2.0
6 * @brief A header for a class to handle plugin loading.
8 * @file ie_plugin_dispatcher.hpp
12 #include <cpp/ie_plugin_cpp.hpp>
16 #include "ie_plugin_ptr.hpp"
18 namespace InferenceEngine {
21 * @deprecated Use InferenceEngine::Core instead.
22 * @brief This is a class to load a suitable plugin
24 class INFERENCE_ENGINE_DEPRECATED("Use InferenceEngine::Core instead which dispatches plugin automatically."
25 "Will be removed in 2020 R2") INFERENCE_ENGINE_API_CLASS(PluginDispatcher) {
28 * @brief A constructor
30 * @param pp Vector of paths to plugin directories
32 explicit PluginDispatcher(const std::vector<file_name_t>& pp = {file_name_t()});
34 IE_SUPPRESS_DEPRECATED_START
37 * @brief Loads a plugin from plugin directories
39 * @param name Plugin name
40 * @return A pointer to the loaded plugin
42 virtual InferencePlugin getPluginByName(const file_name_t& name) const;
45 * @deprecated Use InferenceEngine::Core to work with devices by name
46 * @brief Loads a plugin from directories that is suitable for the device string
48 * @param deviceName A string value representing target device
49 * @return A pointer to the plugin
51 InferencePlugin getPluginByDevice(const std::string& deviceName) const;
53 IE_SUPPRESS_DEPRECATED_END
57 * @brief Creates path to the plugin
59 * @param path Path to the plugin
60 * @param input Plugin name
61 * @return The path to the plugin
63 file_name_t make_plugin_name(const file_name_t& path, const file_name_t& input) const;
66 std::vector<file_name_t> pluginDirs;
68 } // namespace InferenceEngine