blob: 98d7bad4a68c961178147c95b315ba299546d2a0 (
plain)
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
|
/**************************************************************************
A/V Stream Camera Sample
Copyright (c) 2013, Microsoft Corporation.
File:
NonCopyable.h
Abstract:
Simple base class that hides the copy ctor and assignment operators.
Derive from this class any time its not safe (or reasonable) to
permit copies of an object.
History:
created 5/8/2013
**************************************************************************/
#pragma once
//
// General base class for noncopyable objects
//
class CNonCopyable
{
protected:
CNonCopyable() {}
~CNonCopyable() {}
private:
CNonCopyable(
_In_ const CNonCopyable &
)
{}
const CNonCopyable &
operator =(
_In_ const CNonCopyable &
)
{
return *this;
}
};
|