roboligo
Loading...
Searching...
No Matches
Sensor.hpp
Go to the documentation of this file.
1// Copyright 2026 Juan S. Cely G.
2
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6
7// https://www.apache.org/licenses/LICENSE-2.0
8
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
15#ifndef ROBOLIGO_COMMON_CONNECTOR__SENSOR_HPP_
16#define ROBOLIGO_COMMON_CONNECTOR__SENSOR_HPP_
17
20
21namespace roboligo
22{
30 class Sensor : public Linker
31 {
32 public:
38 Sensor(std::string new_name, std::string new_topic);
39
43 virtual ~Sensor() = default;
44
50 void init(std::string new_name, std::string new_topic);
51
52 protected:
53
59 void initialize(std::string new_name, std::string new_topic);
60
62
63 };
64
65} // namespace roboligo
66#endif // ROBOLIGO_COMMON_CONNECTOR__SENSOR_HPP_
Linker()
Default constructor.
Definition Linker.hpp:51
interfaces::modes mode_
The connection mode set to SUBSCRIBER for receiving sensor data.
Definition Sensor.hpp:61
void initialize(std::string new_name, std::string new_topic)
Protected initialization method.
Definition Sensor.cpp:25
virtual ~Sensor()=default
Virtual destructor.
Sensor(std::string new_name, std::string new_topic)
Constructor for Sensor.
Definition Sensor.cpp:19
void init(std::string new_name, std::string new_topic)
Initializes the sensor with a name and topic.
Definition Sensor.cpp:33
modes
Enumeration for interface operational modes.
Definition Interface.hpp:51
@ SUBSCRIBER
Definition Interface.hpp:53
Definition ClassificationBase.hpp:28