MAK RTIspy API Documentation for HLA 1516
Home
Modules
Namespaces
Classes
Files
Examples
Libraries
File List
File Members
libsrc
rtiutil
vlThreadSafeQueue.h
Go to the documentation of this file.
1
/*******************************************************************************
2
** Copyright (c) 2005 MaK Technologies, Inc.
3
** All rights reserved.
4
*******************************************************************************/
5
/*******************************************************************************
6
** $RCSfile: vlThreadSafeQueue.h,v $ $Revision: 1.3 $ $State: Exp $
7
*******************************************************************************/
8
11
12
#ifndef DtThreadSafeQueue_H_
13
#define DtThreadSafeQueue_H_
14
15
#include <vlutil/vlMutex.h>
16
#include <deque>
17
18
27
template
<
class
T >
28
class
DtThreadSafeQueue
29
{
30
public
:
31
33
DtThreadSafeQueue
();
34
36
virtual
~DtThreadSafeQueue
();
37
39
virtual
inline
void
push_back
( std::auto_ptr<T> elem );
40
42
virtual
inline
void
push_front
( std::auto_ptr<T> elem );
43
46
virtual
inline
std::auto_ptr<T>
pop
();
47
48
virtual
inline
size_t
size
()
const
;
49
50
protected
:
51
53
54
std::deque< T* >
myQueue
;
55
57
mutable
MAKRti::DtMutex
myLock
;
58
59
};
60
62
#define DtThreadSafeQueue_Inl_
63
#include "
vlThreadSafeQueue.inl
"
64
#undef DtThreadSafeQueue_Inl_
65
66
#endif
Document ID: Generated on Tue May 7 16:26:47 EDT 2013 from SVN revision 126903
Copyright © 2005-2013 VT MÄK Inc. All Rights Reserved (
www.mak.com
)