Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
include
VimbaCPP
Include
BasicLockable.h
Go to the documentation of this file.
1
/*=============================================================================
2
Copyright (C) 2012 Allied Vision Technologies. All Rights Reserved.
3
4
Redistribution of this file, in original or modified form, without
5
prior written consent of Allied Vision Technologies is prohibited.
6
7
-------------------------------------------------------------------------------
8
9
File: BasicLockable.h
10
11
Description: Definition of class AVT::VmbAPI::BasicLockable.
12
(This include file is for internal use only.)
13
14
-------------------------------------------------------------------------------
15
16
THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED
17
WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF TITLE,
18
NON-INFRINGEMENT, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
19
DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT,
20
INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
21
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
22
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
23
AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
24
TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
25
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26
27
=============================================================================*/
28
29
#ifndef AVT_VMBAPI_BASICLOCKABLE
30
#define AVT_VMBAPI_BASICLOCKABLE
31
32
#include <
VimbaCPP/Include/VimbaCPPCommon.h
>
33
#include <
VimbaCPP/Include/SharedPointerDefines.h
>
34
#include <
VimbaCPP/Include/Mutex.h
>
35
36
namespace
AVT
{
37
namespace
VmbAPI {
38
39
class
BasicLockable
40
{
41
public
:
42
IMEXPORT
BasicLockable
();
43
IMEXPORT
BasicLockable
( MutexPtr pMutex );
44
45
IMEXPORT
virtual
~BasicLockable
();
46
47
MutexPtr
GetMutex
()
const
;
48
49
void
Lock
()
50
{
51
SP_ACCESS
(
m_pMutex
)->Lock();
52
}
53
void
Unlock
()
54
{
55
SP_ACCESS
(
m_pMutex
)->Unlock();
56
}
57
private
:
58
MutexPtr
m_pMutex
;
59
};
60
61
}}
//namespace AVT::VmbAPI
62
63
#endif
AVT::VmbAPI::BasicLockable
Definition:
BasicLockable.h:39
SP_ACCESS
#define SP_ACCESS(sp)
Definition:
SharedPointerDefines.h:50
AVT::VmbAPI::BasicLockable::Unlock
void Unlock()
Definition:
BasicLockable.h:53
AVT::VmbAPI::BasicLockable::~BasicLockable
virtual IMEXPORT ~BasicLockable()
Definition:
BasicLockable.cpp:40
AVT::VmbAPI::BasicLockable::BasicLockable
IMEXPORT BasicLockable()
Definition:
BasicLockable.cpp:35
VimbaCPPCommon.h
AVT::VmbAPI::BasicLockable::Lock
void Lock()
Definition:
BasicLockable.h:49
Mutex.h
SharedPointerDefines.h
AVT::VmbAPI::BasicLockable::GetMutex
MutexPtr GetMutex() const
Definition:
BasicLockable.cpp:49
AVT
Definition:
AncillaryData.h:35
AVT::VmbAPI::BasicLockable::m_pMutex
MutexPtr m_pMutex
Definition:
BasicLockable.h:58
avt_vimba_camera
Author(s): Miquel Massot
, Allied Vision Technologies
autogenerated on Mon Jun 10 2019 12:50:38