IDS peak ICV v1.1.0
Loading...
Searching...
No Matches
peak_common_ipipeline.hpp
Go to the documentation of this file.
1
11#pragma once
12
15#include <peak_common_c/detail/peak_common_defines.h>
16
17#include <memory>
18#include <string>
19#include <vector>
20
37namespace peak
38{
39namespace pipeline
40{
41
54{
55public:
56 virtual ~IPipeline() = default;
57
65 virtual void ExportSettingsToFile(const std::string& filePath) const = 0;
66
74 virtual void ImportSettingsFromFile(const std::string& filePath) = 0;
75
83 PEAK_COMMON_NO_DISCARD virtual std::string ExportSettingsToString() const = 0;
84
92 virtual void ImportSettingsFromString(const std::string& settings) = 0;
93
99 virtual void ResetToDefault() = 0;
100
112 PEAK_COMMON_NO_DISCARD virtual peak::common::Any Process(const peak::common::Any& input) const = 0;
113
126
136 PEAK_COMMON_NO_DISCARD virtual const char* GetType() const = 0;
137
138protected:
146 PEAK_COMMON_NO_DISCARD virtual std::vector<std::shared_ptr<modules::IModule>> GetModules() const = 0;
147};
148
149} // namespace pipeline
150} // namespace peak
A type-erased container for any copyable value.
Interface defining the structure and behavior of a processing pipeline.
virtual ~IPipeline()=default
virtual void ImportSettingsFromFile(const std::string &filePath)=0
Loads the settings of the pipeline and its modules from a file.
virtual std::string ExportSettingsToString() const =0
Returns the current settings of the pipeline and its modules as a string.
virtual peak::common::Any Process(const peak::common::Any &input) const =0
Processes the input through all pipeline modules and returns the result.
virtual void ResetToDefault()=0
Resets the pipeline and its modules to their default state.
virtual peak::common::Any operator<<(const peak::common::Any &input)=0
Convenience operator for processing input using the pipeline.
virtual void ImportSettingsFromString(const std::string &settings)=0
Loads settings for the pipeline and its modules from a string.
virtual const char * GetType() const =0
Returns the type identifier of the pipeline.
virtual void ExportSettingsToFile(const std::string &filePath) const =0
Saves the current settings of the pipeline and its modules to a file.