Skip to main content
aboutsummaryrefslogtreecommitdiffstats
blob: fe9c3639563a8f73a2aeb223a1719951817b269c (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
/*******************************************************************************
 * Copyright (c) 2012 Draeger Medical GmbH (http://www.draeger.com).
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * CONTRIBUTORS:
 * 		Peter Karlitschek (initial contribution)
 *
 *******************************************************************************/

#ifndef RTSERVICES_H_
#define RTSERVICES_H_
#include "common/messaging/MessageServiceController.h"

namespace etRuntime {

class SubSystemClassBase;
class MessageServiceController;


class RTServices {
public:
	virtual ~RTServices();

	static RTServices& getInstance() {
		if (s_instance == 0) {
			s_instance = new RTServices();
		}
		return *s_instance;
	}

	void destroy();
	MessageServiceController& getMsgSvcCtrl();
	SubSystemClassBase* getSubSystem() {	return m_subSystem;	};
	void setSubSystem(SubSystemClassBase* subSystem) { m_subSystem = subSystem;	};

private:
	static RTServices* s_instance;

	SubSystemClassBase* m_subSystem;
	MessageServiceController* m_messageServiceController;

	RTServices();
	RTServices(const RTServices & right);
	RTServices & operator = (const RTServices& right);

};

} /* namespace etRuntime */
#endif /* RTSERVICES_H_ */

Back to the top