YARP
Yet Another Robot Platform
Runnable.h
Go to the documentation of this file.
1 /*
2  * SPDX-FileCopyrightText: 2006-2021 Istituto Italiano di Tecnologia (IIT)
3  * SPDX-FileCopyrightText: 2006-2010 RobotCub Consortium
4  * SPDX-License-Identifier: BSD-3-Clause
5  */
6 
7 #ifndef YARP_OS_RUNNABLE_H
8 #define YARP_OS_RUNNABLE_H
9 
10 #include <yarp/conf/system.h>
11 
12 #if !defined(YARP_INCLUDING_DEPRECATED_HEADER_ON_PURPOSE)
13 YARP_COMPILER_WARNING("<yarp/os/Runnable.h> file is deprecated")
14 #endif
15 
16 #ifndef YARP_NO_DEPRECATED // Since YARP 3.3
17 
18 #include <yarp/os/api.h>
19 
20 namespace yarp {
21 namespace os {
22 
29 {
30 public:
34  virtual ~Runnable();
35 
39  virtual void run();
40 
45  virtual void close();
46 
51  virtual void beforeStart();
52 
57  virtual void afterStart(bool success);
58 
70  virtual bool threadInit();
71 
78  virtual void threadRelease();
79 };
80 
81 } // namespace os
82 } // namespace yarp
83 
84 #endif // YARP_NO_DEPRECATED
85 
86 #endif // YARP_OS_RUNNABLE_H
A class that can be managed by another thread.
Definition: Runnable.h:29
virtual ~Runnable()
Destructor.
The main, catch-all namespace for YARP.
Definition: dirs.h:16
#define YARP_COMPILER_WARNING(x)
Generate a warning at build time on supported compilers.
Definition: system.h:109
#define YARP_os_DEPRECATED_API
Definition: api.h:20