Mech-Eye API 2.3.3
API reference documentation for Mech-Eye 3D Laser Profiler
Loading...
Searching...
No Matches
UserSet.h
1#pragma once
2#include <memory>
3#include <vector>
4#include "api_global.h"
5#include "ErrorStatus.h"
6#include "Parameter.h"
7
8namespace mmind {
9class ZmqClientImpl;
10namespace eye {
11
12class MMIND_API_EXPORT UserSet
13{
14public:
18 virtual ~UserSet();
19
31 ErrorStatus getName(std::string& userSetName) const;
32
46 ErrorStatus rename(const std::string& newName);
47
55 ErrorStatus getAvailableParameterNames(std::vector<std::string>& parameterArrayNames) const;
56
68
81
85 std::vector<Parameter*> getAvailableParameters() const;
86
90 Parameter* getParameter(const std::string& parameterName) const;
91
95 Parameter* operator[](const std::string& parameterName) const;
96
110 ErrorStatus getIntValue(const std::string& parameterName, int& value) const;
111
125 ErrorStatus setIntValue(const std::string& parameterName, int value);
126
140 ErrorStatus getFloatValue(const std::string& parameterName, double& value) const;
141
155 ErrorStatus setFloatValue(const std::string& parameterName, double value);
156
170 ErrorStatus getBoolValue(const std::string& parameterName, bool& value) const;
171
184 ErrorStatus setBoolValue(const std::string& parameterName, bool value);
185
199 ErrorStatus getEnumValue(const std::string& parameterName, int& value) const;
200
215 ErrorStatus setEnumValue(const std::string& parameterName, int value);
216
230 ErrorStatus getEnumValue(const std::string& parameterName, std::string& valueStr) const;
231
246 ErrorStatus setEnumValue(const std::string& parameterName, const std::string& value);
247
261 ErrorStatus getRoiValue(const std::string& parameterName, ROI& value) const;
262
276 ErrorStatus setRoiValue(const std::string& parameterName, const ROI& value);
277
291 ErrorStatus getFloatArrayValue(const std::string& parameterName,
292 std::vector<double>& value) const;
293
307 ErrorStatus setFloatArrayValue(const std::string& parameterName,
308 const std::vector<double>& value);
309
323 ErrorStatus getRangeValue(const std::string& parameterName, Range<int>& value) const;
324
338 ErrorStatus setRangeValue(const std::string& parameterName, const Range<int>& value);
339
340private:
341 std::shared_ptr<class SettingImpl> _impl;
342 explicit UserSet(const std::shared_ptr<ZmqClientImpl>& impl);
343 friend class UserSetManagerImpl;
344};
345
346} // namespace eye
347} // namespace mmind
Represents a parameter of the device.
Definition Parameter.h:23
ErrorStatus setRangeValue(const std::string &parameterName, const Range< int > &value)
Sets the value of a _Range-type device parameter. See Parameter for details.
ErrorStatus getAvailableParameterNames(std::vector< std::string > &parameterArrayNames) const
Gets the names of all available device parameters in the current device user set.
ErrorStatus getEnumValue(const std::string &parameterName, std::string &valueStr) const
Gets the current value of an _Enum-type device parameter in the form of a string. See Parameter for d...
ErrorStatus getIntValue(const std::string &parameterName, int &value) const
Gets the current value of an _Int-type device parameter. See Parameter for details.
ErrorStatus getRoiValue(const std::string &parameterName, ROI &value) const
Gets the current value of an _Roi-type device parameter. See Parameter for details.
ErrorStatus getRangeValue(const std::string &parameterName, Range< int > &value) const
Gets the current value of a _Range-type device parameter. See Parameter for details.
ErrorStatus rename(const std::string &newName)
Renames the current device user set.
ErrorStatus setEnumValue(const std::string &parameterName, const std::string &value)
Sets the value of an _Enum-type device parameter by inputting a string. See Parameter for details.
ErrorStatus getFloatValue(const std::string &parameterName, double &value) const
Gets the current value of a _Float-type device parameter. See Parameter for details.
ErrorStatus setBoolValue(const std::string &parameterName, bool value)
Sets the value of a _Bool-type device parameter. See Parameter for details.
ErrorStatus resetAllParametersToDefaultValues()
Resets all device parameters in the current device user set to default values.
ErrorStatus getFloatArrayValue(const std::string &parameterName, std::vector< double > &value) const
Gets the current value of a _FloatArray-type device parameter. See Parameter for details.
ErrorStatus getName(std::string &userSetName) const
Gets the name of the current device user set.
std::vector< Parameter * > getAvailableParameters() const
Returns the pointers to the elements in the vector storing all available parameters.
Parameter * getParameter(const std::string &parameterName) const
Gets the pointer to the specified device parameter.
virtual ~UserSet()
Destructor.
ErrorStatus saveAllParametersToDevice() const
Saves the values of all device parameters in the current device user set to the device.
ErrorStatus setRoiValue(const std::string &parameterName, const ROI &value)
Sets the value of an _Roi-type device parameter. See Parameter for details.
ErrorStatus setFloatArrayValue(const std::string &parameterName, const std::vector< double > &value)
Sets the value of a _FloatArray-type device parameter. See Parameter for details.
ErrorStatus getEnumValue(const std::string &parameterName, int &value) const
Gets the current value of an _Enum-type device parameter in the form of the integer value....
ErrorStatus getBoolValue(const std::string &parameterName, bool &value) const
Gets the current value of a _Bool-type device parameter. See Parameter for details.
ErrorStatus setFloatValue(const std::string &parameterName, double value)
Sets the value of a _Float-type device parameter. See Parameter for details.
Parameter * operator[](const std::string &parameterName) const
Gets the pointer to the specified device parameter.
ErrorStatus setEnumValue(const std::string &parameterName, int value)
Sets the value of an _Enum-type device parameter by inputting the integer value. See Parameter for de...
ErrorStatus setIntValue(const std::string &parameterName, int value)
Sets the value of an _Int-type device parameter. See Parameter for details.
Describes the types of errors.
Definition ErrorStatus.h:12
Describes a region of interest (ROI).
Definition CommonTypes.h:35
Describes a value range.
Definition CommonTypes.h:11