Fawkes API Fawkes Development Version
syncpoint_manager.cpp
1/***************************************************************************
2 * syncpoint_manager.cpp - SyncPointManager Aspect
3 *
4 * Created: Thu Jan 09 12:25:13 2014
5 * Copyright 2014 Till Hofmann
6 *
7 ****************************************************************************/
8
9/* This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
13 *
14 * This program is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU Library General Public License for more details.
18 *
19 * Read the full text in the LICENSE.GPL file in the doc directory.
20 */
21
22#include <aspect/syncpoint_manager.h>
23
24namespace fawkes {
25
26/** @class SyncPointManagerAspect <aspect/syncpoint_manager.h>
27 * Thread aspect to acces to SyncPoints
28 * Give this aspect to your thread to manage SyncPoints,
29 * i.e. wait for SyncPoints and emit SyncPoints
30 * @ingroup Aspects
31 * @author Till Hofmann
32 */
33
34/** @var SyncPoint * SyncPointManagerAspect::syncpoint_manager
35 * This is the SyncPointManager instance you can use to manage syncpoints.
36 */
37
38/** Constructor. */
40{
41 add_aspect("SyncPointManagerAspect");
43}
44
45SyncPointManagerAspect::~SyncPointManagerAspect()
46{
47}
48
49/** Init SyncPointManager aspect.
50 * This sets the SyncPointManager that can be used to manage SyncPoints.
51 * @param manager SyncPointManager to use
52 */
53void
55{
56 syncpoint_manager = manager;
57}
58
59} // end namespace fawkes
void add_aspect(const char *name)
Add an aspect to a thread.
Definition: aspect.cpp:49
SyncPointManager * syncpoint_manager
This is the SyncPointManager instance you can use to manage syncpoints.
void init_SyncPointManagerAspect(SyncPointManager *syncpoint_manager)
Init SyncPointManager aspect.
This class gives access to SyncPoints.
Fawkes library namespace.