mutex_family.hpp 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. //////////////////////////////////////////////////////////////////////////////
  2. //
  3. // (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost
  4. // Software License, Version 1.0. (See accompanying file
  5. // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  6. //
  7. // See http://www.boost.org/libs/interprocess for documentation.
  8. //
  9. //////////////////////////////////////////////////////////////////////////////
  10. #ifndef BOOST_INTERPROCESS_MUTEX_FAMILY_HPP
  11. #define BOOST_INTERPROCESS_MUTEX_FAMILY_HPP
  12. #ifndef BOOST_CONFIG_HPP
  13. # include <boost/config.hpp>
  14. #endif
  15. #
  16. #if defined(BOOST_HAS_PRAGMA_ONCE)
  17. # pragma once
  18. #endif
  19. #include <boost/interprocess/detail/config_begin.hpp>
  20. #include <boost/interprocess/detail/workaround.hpp>
  21. #include <boost/interprocess/sync/interprocess_mutex.hpp>
  22. #include <boost/interprocess/sync/interprocess_recursive_mutex.hpp>
  23. #include <boost/interprocess/sync/null_mutex.hpp>
  24. //!\file
  25. //!Describes a shared interprocess_mutex family fit algorithm used to allocate objects in shared memory.
  26. namespace boost {
  27. namespace interprocess {
  28. //!Describes interprocess_mutex family to use with Interprocess framework
  29. //!based on boost::interprocess synchronization objects.
  30. struct mutex_family
  31. {
  32. typedef boost::interprocess::interprocess_mutex mutex_type;
  33. typedef boost::interprocess::interprocess_recursive_mutex recursive_mutex_type;
  34. };
  35. //!Describes interprocess_mutex family to use with Interprocess frameworks
  36. //!based on null operation synchronization objects.
  37. struct null_mutex_family
  38. {
  39. typedef boost::interprocess::null_mutex mutex_type;
  40. typedef boost::interprocess::null_mutex recursive_mutex_type;
  41. };
  42. } //namespace interprocess {
  43. } //namespace boost {
  44. #include <boost/interprocess/detail/config_end.hpp>
  45. #endif //#ifndef BOOST_INTERPROCESS_MUTEX_FAMILY_HPP