HORIBA C++ SDK
Library for HORIBA devices
Loading...
Searching...
No Matches
device.h
Go to the documentation of this file.
1#ifndef DEVICE_H
2#define DEVICE_H
3
6
11class Device {
12 public:
13 Device(int id, std::shared_ptr<communication::Communicator> communicator);
14 virtual ~Device() = default;
15
19 virtual void open();
20
24 virtual void close() = 0;
25
26 [[nodiscard]] int device_id() const;
27
28 protected:
30 const communication::Command& command);
31
32 private:
33 int id;
34 std::shared_ptr<communication::Communicator> communicator;
35
36 void handle_errors(const std::vector<std::string>& errors);
37};
38} /* namespace horiba::devices::single_devices */
39#endif /* ifndef DEVICE_H */
Represents a command sent to the ICL.
Definition command.h:13
Represents a response of the ICL.
Definition response.h:13
communication::Response execute_command(const communication::Command &command)
virtual void close()=0
Closes the device.
virtual void open()
Opens the device.
Device(int id, std::shared_ptr< communication::Communicator > communicator)
Definition device_manager.h:7