Methods of Class Mutex
- Mutex
- Mutex();
-
virtual |
abstract |
const |
volatile |
template |
static |
inline |
C-linkage |
NO |
NO |
NO |
NO |
NO |
NO |
YES |
NO |
- Summary
Create a thread-local mutex.
- Return
0 if the mutex could not be created, otherwise a handle to the mutex.
- See Also
- ::osl_createMutex()
- ~Mutex
- ~Mutex();
-
virtual |
abstract |
const |
volatile |
template |
static |
inline |
C-linkage |
NO |
NO |
NO |
NO |
NO |
NO |
YES |
NO |
- Summary
Release the OS-structures and free mutex data-structure.
- See Also
- ::osl_destroyMutex()
- acquire
- sal_Bool acquire();
-
virtual |
abstract |
const |
volatile |
template |
static |
inline |
C-linkage |
NO |
NO |
NO |
NO |
NO |
NO |
YES |
NO |
- Summary
Acquire the mutex, block if already acquired by another thread.
- Return
sal_False if system-call fails.
- See Also
- ::osl_acquireMutex()
- tryToAcquire
- sal_Bool tryToAcquire();
-
virtual |
abstract |
const |
volatile |
template |
static |
inline |
C-linkage |
NO |
NO |
NO |
NO |
NO |
NO |
YES |
NO |
- Summary
Try to acquire the mutex without blocking.
- Return
sal_False if it could not be acquired.
- See Also
- ::osl_tryToAcquireMutex()
- release
- sal_Bool release();
-
virtual |
abstract |
const |
volatile |
template |
static |
inline |
C-linkage |
NO |
NO |
NO |
NO |
NO |
NO |
YES |
NO |
- Summary
Release the mutex.
- Return
sal_False if system-call fails.
- See Also
- ::osl_releaseMutex()
- Mutex
- Mutex(
-
virtual |
abstract |
const |
volatile |
template |
static |
inline |
C-linkage |
NO |
NO |
NO |
NO |
NO |
NO |
NO |
NO |
- Summary
The underlying oslMutex has no reference count.
- Description
Since the underlying oslMutex is not a reference counted object, copy
constructed Mutex may work on an already destructed oslMutex object.
- Mutex
- Mutex(
-
virtual |
abstract |
const |
volatile |
template |
static |
inline |
C-linkage |
NO |
NO |
NO |
NO |
NO |
NO |
NO |
NO |
- Summary
The underlying oslMutex has no reference count.
- Description
When destructed, the Mutex object destroys the undelying oslMutex,
which might cause severe problems in case it's a temporary object.
- operator=
- Mutex & operator=(
-
virtual |
abstract |
const |
volatile |
template |
static |
inline |
C-linkage |
NO |
NO |
NO |
NO |
NO |
NO |
NO |
NO |
- Summary
This assignment operator is private for the same reason as
the copy constructor.
- operator=
- Mutex & operator=(
-
virtual |
abstract |
const |
volatile |
template |
static |
inline |
C-linkage |
NO |
NO |
NO |
NO |
NO |
NO |
NO |
NO |
- Summary
This assignment operator is private for the same reason as
the constructor taking a oslMutex argument.
- getGlobalMutex
- static Mutex * getGlobalMutex();
-
virtual |
abstract |
const |
volatile |
template |
static |
inline |
C-linkage |
NO |
NO |
NO |
NO |
NO |
YES |
YES |
NO |
- Description
Returns a global static mutex object.
The global and static mutex object can be used to initialize other
static objects in a thread safe manner.
- Return
the global mutex object
- See Also
- ::osl_getGlobalMutex()
Top of Page
Copyright © 2000, 2014 LibreOffice contributors and/or their affiliates. All rights reserved.
LibreOffice was created by The Document Foundation, based on OpenOffice.org, which is Copyright 2000, 2010 Oracle and/or its affiliates.
The Document Foundation acknowledges all community members, please find more info at our website.
Privacy Policy | Impressum (Legal Info) | Copyright information: The source code of LibreOffice is licensed under the GNU Lesser General Public License (LGPLv3). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.