cisst-saw
Loading...
Searching...
No Matches
osaThreadBuddy.h
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/* ex: set filetype=cpp softtabstop=4 shiftwidth=4 tabstop=4 cindent expandtab: */
3
4/*
5
6 Author(s): Ankur Kapoor, Min Yang Jung
7 Created on: 2004-04-30
8
9 (C) Copyright 2004-2010 Johns Hopkins University (JHU), All Rights
10 Reserved.
11
12--- begin cisst license - do not edit ---
13
14This software is provided "as is" under an open source license, with
15no warranty. The complete license can be found in license.txt and
16http://www.cisst.org/cisst/license.txt.
17
18--- end cisst license ---
19*/
20
21
26
27#ifndef _osaThreadBuddy_h
28#define _osaThreadBuddy_h
29
33
34// Always include last
36
42
47
48
49struct osaThreadBuddyInternals;
50
64
65 osaThreadBuddyInternals* Data;
66
68 double Period;
69
70public:
73
76
86 void Create(const char *name, double period, int stack_size = 1024*256);
87 void Create(const char *name, const osaAbsoluteTime& tv, int stack_size = 1024*256 );
88
90 void Delete();
91
94 bool IsPeriodic() const { return Period > 0; }
95
98 void WaitForPeriod(void);
99
103
106
109
111 void Resume(void);
112
114 void Suspend(void);
115
117 void LockStack();
118
121};
122
123
124#endif // _osaThreadBuddy_h
125
void Suspend(void)
void Create(const char *name, double period, int stack_size=1024 *256)
void Resume(void)
void WaitForPeriod(void)
void Create(const char *name, const osaAbsoluteTime &tv, int stack_size=1024 *256)
void WaitForRemainingPeriod(void)
bool IsPeriodic() const
Definition osaThreadBuddy.h:94
void MakeHardRealTime(void)
void MakeSoftRealTime(void)
void UnlockStack()
#define CISST_EXPORT
Definition cmnExportMacros.h:50
Portability across compilers and operating systems tools.
CISST_EXPORT void __os_exit(void)
CISST_EXPORT void __os_init(void)
Macros to export the symbols of cisstOSAbstraction (in a Dll).
Declaration of osaThread.
Declaration of osaTimeServer class.
Definition osaTimeServer.h:36