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
4
#include <
horiba_cpp_sdk/communication/communicator.h
>
5
#include <
horiba_cpp_sdk/communication/response.h
>
6
7
namespace
horiba::devices::single_devices
{
11
class
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
:
29
communication::Response
execute_command
(
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 */
horiba::communication::Command
Represents a command sent to the ICL.
Definition
command.h:13
horiba::communication::Response
Represents a response of the ICL.
Definition
response.h:13
horiba::devices::single_devices::Device::execute_command
communication::Response execute_command(const communication::Command &command)
horiba::devices::single_devices::Device::~Device
virtual ~Device()=default
horiba::devices::single_devices::Device::close
virtual void close()=0
Closes the device.
horiba::devices::single_devices::Device::open
virtual void open()
Opens the device.
horiba::devices::single_devices::Device::device_id
int device_id() const
horiba::devices::single_devices::Device::Device
Device(int id, std::shared_ptr< communication::Communicator > communicator)
communicator.h
horiba::devices::single_devices
Definition
device_manager.h:7
response.h
include
horiba_cpp_sdk
devices
single_devices
device.h
Generated by
1.13.2