icl_core_thread/ThreadImplLxrt38.h
Go to the documentation of this file.
1 // this is for emacs file handling -*- mode: c++; indent-tabs-mode: nil -*-
2 
3 // -- BEGIN LICENSE BLOCK ----------------------------------------------
4 // This file is part of FZIs ic_workspace.
5 //
6 // This program is free software licensed under the LGPL
7 // (GNU LESSER GENERAL PUBLIC LICENSE Version 3).
8 // You can find a copy of this license in LICENSE folder in the top
9 // directory of the source code.
10 //
11 // © Copyright 2016 FZI Forschungszentrum Informatik, Karlsruhe, Germany
12 //
13 // -- END LICENSE BLOCK ------------------------------------------------
14 
15 //----------------------------------------------------------------------
30 //----------------------------------------------------------------------
31 #ifndef ICL_CORE_THREAD_THREAD_IMPL_LXRT38_H_INCLUDED
32 #define ICL_CORE_THREAD_THREAD_IMPL_LXRT38_H_INCLUDED
33 
34 #include <rtai_posix.h>
35 #include <rtai_sem.h>
36 
37 #include <icl_core/os_thread.h>
38 
40 
41 namespace icl_core {
42 namespace thread {
43 
44 class Thread;
45 
50 class ThreadImplLxrt38 : public ThreadImpl, protected virtual icl_core::Noncopyable
51 {
52 public:
53  ThreadImplLxrt38(Thread *thread, const icl_core::String& description,
55 
56  virtual ~ThreadImplLxrt38();
57 
58  virtual void cancel();
59  virtual icl_core::String getDescription() const { return m_description; }
60  virtual bool isHardRealtime() const;
61  virtual bool executesHardRealtime() const;
62  virtual void join();
63  virtual icl_core::ThreadPriority priority() const;
64  virtual void setDescription(const icl_core::String& description) { m_description = description; }
65  virtual bool setHardRealtime(bool hard_realtime);
66  virtual bool setPriority(icl_core::ThreadPriority priority);
67  virtual bool start();
68  virtual icl_core::ThreadId threadId() const;
69 
70 private:
71  static void *runThread(void *arg);
72 
73  pthread_t m_thread_id;
77 
78  RT_TASK *m_rt_task;
79 
81 };
82 
83 }
84 }
85 
86 #endif
ICL_CORE_OS_IMPL_NS::ThreadId ThreadId
Definition: os_thread.h:49
virtual icl_core::ThreadPriority priority() const
Contains icl_core::thread::ThreadImpl.
virtual icl_core::ThreadId threadId() const
virtual icl_core::String getDescription() const
Contains global thread related functions, encapsulated into the icl_core::os namespace.
ThreadImplLxrt38(Thread *thread, const icl_core::String &description, icl_core::ThreadPriority priority)
virtual bool setPriority(icl_core::ThreadPriority priority)
std::string String
Definition: BaseTypes.h:43
virtual void setDescription(const icl_core::String &description)
int32_t ThreadPriority
Definition: os_thread.h:50


fzi_icl_core
Author(s):
autogenerated on Mon Jun 10 2019 13:17:58