LRT14
1.0
Main Page
Namespaces
Classes
Files
File List
All
Classes
Namespaces
Functions
Variables
Enumerations
Enumerator
ContainerCleanup.h
1
#ifndef RHESUS_CONTAINERCLEANUP_H_
2
#define RHESUS_CONTAINERCLEANUP_H_
3
4
#include <queue>
5
#include "../Defines.h"
6
7
namespace
Rhesus
8
{
9
namespace
Toolkit
10
{
11
namespace
Utilities
12
{
13
class
ContainerCleanup
14
{
15
public
:
19
template
<
class
A>
20
static
bool
DeleteVector(A x)
21
{
22
if
(x == NULL)
23
return
true
;
24
25
DELETE(x);
26
27
return
true
;
28
}
29
33
template
<
class
T>
34
static
void
ClearQueue(std::queue<T>& q)
35
{
36
std::queue<T> empty;
37
std::swap(q, empty);
38
}
39
};
40
}
41
}
42
}
43
44
#endif
Rhesus
Toolkit
Utilities
ContainerCleanup.h
Generated on Tue Feb 11 2014 00:29:49 for LRT14 by
1.8.3