|
||||
File indexing completed on 2025-01-30 09:33:45
0001 // 0002 // placeholders.hpp 0003 // ~~~~~~~~~~~~~~~~ 0004 // 0005 // Copyright (c) 2003-2023 Christopher M. Kohlhoff (chris at kohlhoff dot com) 0006 // 0007 // Distributed under the Boost Software License, Version 1.0. (See accompanying 0008 // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 0009 // 0010 0011 #ifndef BOOST_ASIO_PLACEHOLDERS_HPP 0012 #define BOOST_ASIO_PLACEHOLDERS_HPP 0013 0014 #if defined(_MSC_VER) && (_MSC_VER >= 1200) 0015 # pragma once 0016 #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 0017 0018 #include <boost/asio/detail/config.hpp> 0019 #include <boost/asio/detail/functional.hpp> 0020 0021 #include <boost/asio/detail/push_options.hpp> 0022 0023 namespace boost { 0024 namespace asio { 0025 namespace placeholders { 0026 0027 #if defined(GENERATING_DOCUMENTATION) 0028 0029 /// An argument placeholder, for use with std::bind() or boost::bind(), that 0030 /// corresponds to the error argument of a handler for any of the asynchronous 0031 /// functions. 0032 unspecified error; 0033 0034 /// An argument placeholder, for use with std::bind() or boost::bind(), that 0035 /// corresponds to the bytes_transferred argument of a handler for asynchronous 0036 /// functions such as boost::asio::basic_stream_socket::async_write_some or 0037 /// boost::asio::async_write. 0038 unspecified bytes_transferred; 0039 0040 /// An argument placeholder, for use with std::bind() or boost::bind(), that 0041 /// corresponds to the iterator argument of a handler for asynchronous functions 0042 /// such as boost::asio::async_connect. 0043 unspecified iterator; 0044 0045 /// An argument placeholder, for use with std::bind() or boost::bind(), that 0046 /// corresponds to the results argument of a handler for asynchronous functions 0047 /// such as boost::asio::basic_resolver::async_resolve. 0048 unspecified results; 0049 0050 /// An argument placeholder, for use with std::bind() or boost::bind(), that 0051 /// corresponds to the results argument of a handler for asynchronous functions 0052 /// such as boost::asio::async_connect. 0053 unspecified endpoint; 0054 0055 /// An argument placeholder, for use with std::bind() or boost::bind(), that 0056 /// corresponds to the signal_number argument of a handler for asynchronous 0057 /// functions such as boost::asio::signal_set::async_wait. 0058 unspecified signal_number; 0059 0060 #else 0061 0062 static constexpr auto& error = std::placeholders::_1; 0063 static constexpr auto& bytes_transferred = std::placeholders::_2; 0064 static constexpr auto& iterator = std::placeholders::_2; 0065 static constexpr auto& results = std::placeholders::_2; 0066 static constexpr auto& endpoint = std::placeholders::_2; 0067 static constexpr auto& signal_number = std::placeholders::_2; 0068 0069 #endif 0070 0071 } // namespace placeholders 0072 } // namespace asio 0073 } // namespace boost 0074 0075 #include <boost/asio/detail/pop_options.hpp> 0076 0077 #endif // BOOST_ASIO_PLACEHOLDERS_HPP
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |