null_rw_mutex.h
Go to the documentation of this file.
/*
Copyright (c) 2005-2020 Intel Corporation
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
#ifndef __TBB_null_rw_mutex_H
#define __TBB_null_rw_mutex_H
#include "tbb_stddef.h"
namespace tbb {
class null_rw_mutex : internal::mutex_copy_deprecated_and_disabled {
public:
class scoped_lock : internal::no_copy {
public:
scoped_lock() {}
scoped_lock( null_rw_mutex& , bool = true ) {}
~scoped_lock() {}
void acquire( null_rw_mutex& , bool = true ) {}
bool upgrade_to_writer() { return true; }
bool downgrade_to_reader() { return true; }
bool try_acquire( null_rw_mutex& , bool = true ) { return true; }
void release() {}
};
null_rw_mutex() {}
// Mutex traits
static const bool is_rw_mutex = true;
static const bool is_recursive_mutex = true;
static const bool is_fair_mutex = true;
};
}
#endif /* __TBB_null_rw_mutex_H */
tbb::null_rw_mutex::scoped_lock::scoped_lock
scoped_lock()
Definition: null_rw_mutex.h:32
tbb::null_rw_mutex::scoped_lock::~scoped_lock
~scoped_lock()
Definition: null_rw_mutex.h:34
tbb::null_rw_mutex::scoped_lock
Represents acquisition of a mutex.
Definition: null_rw_mutex.h:30
tbb::internal::no_copy
Base class for types that should not be copied or assigned.
Definition: tbb_stddef.h:330
tbb::null_rw_mutex::is_fair_mutex
static const bool is_fair_mutex
Definition: null_rw_mutex.h:47
tbb::null_rw_mutex::is_rw_mutex
static const bool is_rw_mutex
Definition: null_rw_mutex.h:45
tbb
The graph class.
Definition: serial/tbb/parallel_for.h:46
tbb::null_rw_mutex::scoped_lock::downgrade_to_reader
bool downgrade_to_reader()
Definition: null_rw_mutex.h:37
tbb::null_rw_mutex::scoped_lock::scoped_lock
scoped_lock(null_rw_mutex &, bool=true)
Definition: null_rw_mutex.h:33
tbb::null_rw_mutex::null_rw_mutex
null_rw_mutex()
Definition: null_rw_mutex.h:42
tbb::null_rw_mutex::scoped_lock::upgrade_to_writer
bool upgrade_to_writer()
Definition: null_rw_mutex.h:36
tbb::internal::mutex_copy_deprecated_and_disabled
Definition: tbb_stddef.h:365
tbb::null_rw_mutex::scoped_lock::acquire
void acquire(null_rw_mutex &, bool=true)
Definition: null_rw_mutex.h:35
tbb::null_rw_mutex
A rw mutex which does nothing.
Definition: null_rw_mutex.h:27
tbb::null_rw_mutex::scoped_lock::try_acquire
bool try_acquire(null_rw_mutex &, bool=true)
Definition: null_rw_mutex.h:38
tbb::null_rw_mutex::is_recursive_mutex
static const bool is_recursive_mutex
Definition: null_rw_mutex.h:46
tbb_stddef.h
tbb::null_rw_mutex::scoped_lock::release
void release()
Definition: null_rw_mutex.h:39

Copyright © 2005-2020 Intel Corporation. All Rights Reserved.

Intel, Pentium, Intel Xeon, Itanium, Intel XScale and VTune are registered trademarks or trademarks of Intel Corporation or its subsidiaries in the United States and other countries.

* Other names and brands may be claimed as the property of others.