passenger 6.0.26 → 6.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (915) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG +38 -1
  3. data/CONTRIBUTING.md +2 -2
  4. data/CONTRIBUTORS +2 -0
  5. data/bin/passenger-install-apache2-module +6 -3
  6. data/bin/passenger-install-nginx-module +8 -3
  7. data/build/agent.rb +0 -2
  8. data/build/basics.rb +2 -0
  9. data/build/common_library.rb +0 -6
  10. data/build/misc.rb +0 -2
  11. data/build/schema_printer.rb +0 -2
  12. data/build/support/cxx_dependency_map.rb +60 -875
  13. data/dev/copy_boost_headers +3 -14
  14. data/dev/index_cxx_dependencies.rb +5 -1
  15. data/doc/AiInstructions.md +112 -0
  16. data/doc/CxxMockingStrategy.md +42 -0
  17. data/doc/CxxTestingGuide.md +110 -0
  18. data/doc/DesignAspects/LimitedGemDependencies.md +22 -14
  19. data/doc/TempFileHandling.md +15 -0
  20. data/package.json +1 -1
  21. data/passenger.gemspec +1 -1
  22. data/resources/templates/standalone/server.erb +1 -0
  23. data/src/agent/Core/ApiServer.h +0 -1
  24. data/src/agent/Core/ApplicationPool/AbstractSession.h +10 -1
  25. data/src/agent/Core/ApplicationPool/Group/ProcessListManagement.cpp +1 -1
  26. data/src/agent/Core/ApplicationPool/Group/SessionManagement.cpp +33 -18
  27. data/src/agent/Core/ApplicationPool/Group.h +0 -1
  28. data/src/agent/Core/ApplicationPool/Implementation.cpp +1 -4
  29. data/src/agent/Core/ApplicationPool/Session.h +14 -19
  30. data/src/agent/Core/ApplicationPool/Socket.h +15 -5
  31. data/src/agent/Core/ApplicationPool/TestSession.h +73 -15
  32. data/src/agent/Core/Config.h +2 -39
  33. data/src/agent/Core/ConfigChange.cpp +1 -41
  34. data/src/agent/Core/Controller/CheckoutSession.cpp +100 -14
  35. data/src/agent/Core/Controller/Client.h +0 -1
  36. data/src/agent/Core/Controller/Config.h +1 -1
  37. data/src/agent/Core/Controller/Hooks.cpp +13 -0
  38. data/src/agent/Core/Controller/InitRequest.cpp +2 -0
  39. data/src/agent/Core/Controller/InternalUtils.cpp +12 -0
  40. data/src/agent/Core/Controller/Request.h +3 -2
  41. data/src/agent/Core/Controller.h +12 -13
  42. data/src/agent/Core/CoreMain.cpp +2 -56
  43. data/src/agent/Core/OptionParser.h +1 -7
  44. data/src/agent/Core/SecurityUpdateChecker.h +10 -2
  45. data/src/agent/Core/SpawningKit/Exceptions.h +0 -1
  46. data/src/agent/Core/SpawningKit/Handshake/Perform.h +13 -2
  47. data/src/agent/Shared/Fundamentals/AbortHandler.cpp +23 -5
  48. data/src/agent/Shared/Fundamentals/AbortHandler.h +10 -22
  49. data/src/agent/Shared/Fundamentals/Initialization.cpp +1 -0
  50. data/src/agent/Watchdog/Config.h +2 -21
  51. data/src/agent/Watchdog/WatchdogMain.cpp +0 -2
  52. data/src/apache2_module/ConfigGeneral/AutoGeneratedDefinitions.cpp +5 -20
  53. data/src/apache2_module/ConfigGeneral/AutoGeneratedManifestDefaultsInitialization.cpp +5 -0
  54. data/src/apache2_module/ConfigGeneral/AutoGeneratedSetterFuncs.cpp +14 -60
  55. data/src/apache2_module/DirConfig/AutoGeneratedCreateFunction.cpp +3 -0
  56. data/src/apache2_module/DirConfig/AutoGeneratedHeaderSerialization.cpp +3 -0
  57. data/src/apache2_module/DirConfig/AutoGeneratedManifestGeneration.cpp +11 -0
  58. data/src/apache2_module/DirConfig/AutoGeneratedMergeFunction.cpp +7 -0
  59. data/src/apache2_module/DirConfig/AutoGeneratedStruct.h +17 -0
  60. data/src/apache2_module/Hooks.cpp +0 -10
  61. data/src/apache2_module/ServerConfig/AutoGeneratedManifestGeneration.cpp +0 -44
  62. data/src/apache2_module/ServerConfig/AutoGeneratedStruct.h +0 -52
  63. data/src/cxx_supportlib/Algorithms/Hasher.cpp +1 -1
  64. data/src/cxx_supportlib/Algorithms/Hasher.h +4 -7
  65. data/src/cxx_supportlib/Algorithms/MovingAverage.h +1 -160
  66. data/src/cxx_supportlib/ConfigKit/IN_PRACTICE.md +2 -12
  67. data/src/cxx_supportlib/ConfigKit/Store.h +1 -6
  68. data/src/cxx_supportlib/Constants.h +2 -1
  69. data/src/cxx_supportlib/DataStructures/StringKeyTable.h +1 -7
  70. data/src/cxx_supportlib/DataStructures/StringMap.h +2 -3
  71. data/src/cxx_supportlib/Exceptions.cpp +178 -0
  72. data/src/cxx_supportlib/Exceptions.h +62 -177
  73. data/src/cxx_supportlib/FileTools/FileManip.h +2 -0
  74. data/src/cxx_supportlib/Hooks.h +0 -1
  75. data/src/cxx_supportlib/IOTools/IOUtils.cpp +266 -250
  76. data/src/cxx_supportlib/IOTools/IOUtils.h +87 -132
  77. data/src/cxx_supportlib/ServerKit/AcceptLoadBalancer.h +2 -0
  78. data/src/cxx_supportlib/ServerKit/Config.h +1 -6
  79. data/src/cxx_supportlib/ServerKit/FileBufferedChannel.h +1 -1
  80. data/src/cxx_supportlib/ServerKit/HttpHeaderParser.h +8 -6
  81. data/src/cxx_supportlib/StaticString.h +1 -6
  82. data/src/cxx_supportlib/StrIntTools/StrIntUtils.h +2 -2
  83. data/src/cxx_supportlib/SystemTools/SystemMetricsCollector.h +0 -2
  84. data/src/cxx_supportlib/Utils/Curl.h +1 -6
  85. data/src/cxx_supportlib/Utils/FastStringStream.h +7 -7
  86. data/src/cxx_supportlib/Utils/IniFile.h +24 -25
  87. data/src/cxx_supportlib/Utils/ScopeGuard.h +0 -32
  88. data/src/cxx_supportlib/Utils.h +0 -30
  89. data/src/cxx_supportlib/oxt/detail/tracable_exception_disabled.hpp +4 -0
  90. data/src/cxx_supportlib/oxt/detail/tracable_exception_enabled.hpp +1 -0
  91. data/src/cxx_supportlib/oxt/implementation.cpp +41 -2
  92. data/src/cxx_supportlib/oxt/spin_lock.hpp +94 -23
  93. data/src/cxx_supportlib/oxt/system_calls.cpp +1 -0
  94. data/src/cxx_supportlib/oxt/system_calls.hpp +3 -4
  95. data/src/cxx_supportlib/vendor-modified/boost/container/allocator.hpp +2 -2
  96. data/src/cxx_supportlib/vendor-modified/boost/container/deque.hpp +5 -0
  97. data/src/cxx_supportlib/vendor-modified/boost/container/detail/config_begin.hpp +1 -0
  98. data/src/cxx_supportlib/vendor-modified/boost/container/detail/container_or_allocator_rebind.hpp +1 -2
  99. data/src/cxx_supportlib/vendor-modified/boost/container/detail/container_rebind.hpp +23 -13
  100. data/src/cxx_supportlib/vendor-modified/boost/container/detail/flat_tree.hpp +72 -49
  101. data/src/cxx_supportlib/vendor-modified/boost/container/detail/function_detector.hpp +1 -1
  102. data/src/cxx_supportlib/vendor-modified/boost/container/detail/is_contiguous_container.hpp +15 -11
  103. data/src/cxx_supportlib/vendor-modified/boost/container/detail/tree.hpp +4 -0
  104. data/src/cxx_supportlib/vendor-modified/boost/container/devector.hpp +36 -9
  105. data/src/cxx_supportlib/vendor-modified/boost/container/flat_map.hpp +9 -2
  106. data/src/cxx_supportlib/vendor-modified/boost/container/list.hpp +4 -0
  107. data/src/cxx_supportlib/vendor-modified/boost/container/options.hpp +21 -17
  108. data/src/cxx_supportlib/vendor-modified/boost/container/slist.hpp +5 -0
  109. data/src/cxx_supportlib/vendor-modified/boost/container/small_vector.hpp +10 -6
  110. data/src/cxx_supportlib/vendor-modified/boost/container/stable_vector.hpp +8 -3
  111. data/src/cxx_supportlib/vendor-modified/boost/container/static_vector.hpp +21 -3
  112. data/src/cxx_supportlib/vendor-modified/boost/container/string.hpp +5 -15
  113. data/src/cxx_supportlib/vendor-modified/boost/container/vector.hpp +73 -14
  114. data/src/cxx_supportlib/vendor-modified/boost/detail/basic_pointerbuf.hpp +1 -2
  115. data/src/cxx_supportlib/vendor-modified/boost/detail/lcast_precision.hpp +18 -29
  116. data/src/cxx_supportlib/vendor-modified/boost/function/function_template.hpp +7 -7
  117. data/src/cxx_supportlib/vendor-modified/boost/integer/common_factor_rt.hpp +6 -10
  118. data/src/cxx_supportlib/vendor-modified/boost/intrusive/avl_set.hpp +8 -0
  119. data/src/cxx_supportlib/vendor-modified/boost/intrusive/avltree.hpp +4 -0
  120. data/src/cxx_supportlib/vendor-modified/boost/intrusive/bs_set.hpp +8 -0
  121. data/src/cxx_supportlib/vendor-modified/boost/intrusive/bstree.hpp +12 -4
  122. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/function_detector.hpp +1 -1
  123. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/parent_from_member.hpp +5 -4
  124. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/workaround.hpp +10 -0
  125. data/src/cxx_supportlib/vendor-modified/boost/intrusive/list.hpp +5 -0
  126. data/src/cxx_supportlib/vendor-modified/boost/intrusive/rbtree.hpp +4 -0
  127. data/src/cxx_supportlib/vendor-modified/boost/intrusive/set.hpp +8 -0
  128. data/src/cxx_supportlib/vendor-modified/boost/intrusive/sg_set.hpp +8 -0
  129. data/src/cxx_supportlib/vendor-modified/boost/intrusive/sgtree.hpp +4 -0
  130. data/src/cxx_supportlib/vendor-modified/boost/intrusive/slist.hpp +5 -0
  131. data/src/cxx_supportlib/vendor-modified/boost/intrusive/splay_set.hpp +8 -0
  132. data/src/cxx_supportlib/vendor-modified/boost/intrusive/splaytree.hpp +4 -0
  133. data/src/cxx_supportlib/vendor-modified/boost/intrusive/treap.hpp +4 -0
  134. data/src/cxx_supportlib/vendor-modified/boost/intrusive/treap_set.hpp +8 -0
  135. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast/detail/converter_lexical_streams.hpp +7 -7
  136. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast/detail/inf_nan.hpp +1 -1
  137. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast/detail/lcast_unsigned_converters.hpp +1 -1
  138. data/src/cxx_supportlib/vendor-modified/boost/move/adl_move_swap.hpp +2 -0
  139. data/src/cxx_supportlib/vendor-modified/boost/move/core.hpp +4 -4
  140. data/src/cxx_supportlib/vendor-modified/boost/move/detail/meta_utils.hpp +1 -20
  141. data/src/cxx_supportlib/vendor-modified/boost/move/detail/meta_utils_core.hpp +15 -0
  142. data/src/cxx_supportlib/vendor-modified/boost/move/detail/nsec_clock.hpp +1 -1
  143. data/src/cxx_supportlib/vendor-modified/boost/move/detail/placement_new.hpp +2 -0
  144. data/src/cxx_supportlib/vendor-modified/boost/move/detail/std_ns_begin.hpp +7 -7
  145. data/src/cxx_supportlib/vendor-modified/boost/move/detail/std_ns_end.hpp +3 -0
  146. data/src/cxx_supportlib/vendor-modified/boost/mp11/detail/mp_count.hpp +4 -4
  147. data/src/cxx_supportlib/vendor-modified/boost/mp11/version.hpp +1 -1
  148. data/src/cxx_supportlib/vendor-modified/boost/none.hpp +1 -1
  149. data/src/cxx_supportlib/vendor-modified/boost/none_t.hpp +10 -4
  150. data/src/cxx_supportlib/vendor-modified/boost/optional/detail/experimental_traits.hpp +4 -49
  151. data/src/cxx_supportlib/vendor-modified/boost/optional/detail/optional_aligned_storage.hpp +2 -3
  152. data/src/cxx_supportlib/vendor-modified/boost/optional/detail/optional_config.hpp +13 -4
  153. data/src/cxx_supportlib/vendor-modified/boost/optional/detail/optional_reference_spec.hpp +47 -46
  154. data/src/cxx_supportlib/vendor-modified/boost/optional/detail/optional_relops.hpp +11 -11
  155. data/src/cxx_supportlib/vendor-modified/boost/optional/detail/optional_swap.hpp +3 -3
  156. data/src/cxx_supportlib/vendor-modified/boost/optional/detail/optional_trivially_copyable_base.hpp +12 -252
  157. data/src/cxx_supportlib/vendor-modified/boost/optional/detail/optional_utility.hpp +41 -0
  158. data/src/cxx_supportlib/vendor-modified/boost/optional/optional.hpp +101 -592
  159. data/src/cxx_supportlib/vendor-modified/boost/optional/optional_io.hpp +1 -5
  160. data/src/cxx_supportlib/vendor-modified/boost/pointer_cast.hpp +12 -24
  161. data/src/cxx_supportlib/vendor-modified/boost/random/beta_distribution.hpp +5 -5
  162. data/src/cxx_supportlib/vendor-modified/boost/random/hyperexponential_distribution.hpp +15 -15
  163. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/allocate_shared_array.hpp +37 -44
  164. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/bad_weak_ptr.hpp +1 -23
  165. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/atomic_count.hpp +1 -0
  166. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/deprecated_macros.hpp +52 -0
  167. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/local_counted_base.hpp +14 -18
  168. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/local_sp_deleter.hpp +7 -15
  169. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/shared_count.hpp +39 -90
  170. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_convertible.hpp +0 -16
  171. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base.hpp +1 -0
  172. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_nt.hpp +13 -14
  173. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_std_atomic.hpp +16 -17
  174. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_impl.hpp +16 -55
  175. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_noexcept.hpp +5 -14
  176. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_type_traits.hpp +55 -0
  177. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/spinlock.hpp +1 -0
  178. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/spinlock_std_atomic.hpp +5 -6
  179. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/enable_shared_from_this.hpp +7 -10
  180. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/intrusive_ptr.hpp +32 -110
  181. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/intrusive_ref_counter.hpp +17 -18
  182. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/make_shared.hpp +2 -6
  183. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/make_shared_array.hpp +10 -9
  184. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/make_shared_object.hpp +28 -565
  185. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/make_unique.hpp +11 -17
  186. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/scoped_array.hpp +17 -21
  187. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/scoped_ptr.hpp +20 -22
  188. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/shared_array.hpp +34 -68
  189. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/shared_ptr.hpp +78 -356
  190. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/weak_ptr.hpp +31 -89
  191. data/src/cxx_supportlib/vendor-modified/boost/unordered/concurrent_flat_map.hpp +195 -12
  192. data/src/cxx_supportlib/vendor-modified/boost/unordered/concurrent_flat_set.hpp +206 -17
  193. data/src/cxx_supportlib/vendor-modified/boost/unordered/concurrent_node_map.hpp +1202 -0
  194. data/src/cxx_supportlib/vendor-modified/boost/unordered/concurrent_node_map_fwd.hpp +67 -0
  195. data/src/cxx_supportlib/vendor-modified/boost/unordered/concurrent_node_set.hpp +1065 -0
  196. data/src/cxx_supportlib/vendor-modified/boost/unordered/concurrent_node_set_fwd.hpp +67 -0
  197. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/concurrent_static_asserts.hpp +30 -8
  198. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/foa/concurrent_table.hpp +248 -47
  199. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/foa/core.hpp +24 -0
  200. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/foa/flat_map_types.hpp +10 -2
  201. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/foa/flat_set_types.hpp +8 -2
  202. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/foa/node_handle.hpp +120 -5
  203. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/foa/node_map_handle.hpp +56 -0
  204. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/foa/node_map_types.hpp +15 -4
  205. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/foa/node_set_handle.hpp +48 -0
  206. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/foa/node_set_types.hpp +13 -4
  207. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/foa/tuple_rotate_right.hpp +11 -10
  208. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/foa/types_constructibility.hpp +172 -0
  209. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/implementation.hpp +1 -0
  210. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/map.hpp +0 -17
  211. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/set.hpp +0 -17
  212. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/type_traits.hpp +11 -0
  213. data/src/cxx_supportlib/vendor-modified/boost/unordered/unordered_flat_map.hpp +9 -0
  214. data/src/cxx_supportlib/vendor-modified/boost/unordered/unordered_flat_set.hpp +9 -0
  215. data/src/cxx_supportlib/vendor-modified/boost/unordered/unordered_map.hpp +2 -2
  216. data/src/cxx_supportlib/vendor-modified/boost/unordered/unordered_node_map.hpp +32 -44
  217. data/src/cxx_supportlib/vendor-modified/boost/unordered/unordered_node_set.hpp +31 -35
  218. data/src/cxx_supportlib/vendor-modified/boost/unordered/unordered_printers.hpp +414 -0
  219. data/src/cxx_supportlib/vendor-modified/boost/unordered/unordered_set.hpp +2 -2
  220. data/src/cxx_supportlib/vendor-modified/boost/version.hpp +2 -2
  221. data/src/nginx_module/ConfigGeneral/AutoGeneratedDefinitions.c +8 -32
  222. data/src/nginx_module/ConfigGeneral/AutoGeneratedManifestDefaultsInitialization.c +6 -0
  223. data/src/nginx_module/ConfigGeneral/AutoGeneratedSetterFuncs.c +12 -48
  224. data/src/nginx_module/LocationConfig/AutoGeneratedCreateFunction.c +5 -0
  225. data/src/nginx_module/LocationConfig/AutoGeneratedHeaderSerialization.c +21 -0
  226. data/src/nginx_module/LocationConfig/AutoGeneratedManifestGeneration.c +13 -0
  227. data/src/nginx_module/LocationConfig/AutoGeneratedMergeFunction.c +3 -0
  228. data/src/nginx_module/LocationConfig/AutoGeneratedStruct.h +4 -0
  229. data/src/nginx_module/MainConfig/AutoGeneratedCreateFunction.c +0 -24
  230. data/src/nginx_module/MainConfig/AutoGeneratedManifestGeneration.c +0 -48
  231. data/src/nginx_module/MainConfig/AutoGeneratedStruct.h +0 -16
  232. data/src/nginx_module/ngx_http_passenger_module.c +0 -4
  233. data/src/ruby_native_extension/passenger_native_support.c +19 -3
  234. data/src/ruby_supportlib/phusion_passenger/apache2/config_options.rb +8 -24
  235. data/src/ruby_supportlib/phusion_passenger/common_library.rb +0 -3
  236. data/src/ruby_supportlib/phusion_passenger/constants.rb +1 -0
  237. data/src/ruby_supportlib/phusion_passenger/nginx/config_options.rb +6 -28
  238. data/src/ruby_supportlib/phusion_passenger/platform_info/compiler.rb +15 -18
  239. data/src/ruby_supportlib/phusion_passenger/platform_info/cxx_portability.rb +4 -29
  240. data/src/ruby_supportlib/phusion_passenger/platform_info/operating_system.rb +0 -30
  241. data/src/ruby_supportlib/phusion_passenger/rack_handler.rb +2 -2
  242. data/src/ruby_supportlib/phusion_passenger/standalone/config_options_list.rb +8 -20
  243. data/src/ruby_supportlib/phusion_passenger.rb +7 -7
  244. data/src/schema_printer/SchemaPrinterMain.cpp +0 -4
  245. metadata +20 -675
  246. data/dev/websocketpp.patch +0 -39
  247. data/src/agent/Core/AdminPanelConnector.h +0 -680
  248. data/src/cxx_supportlib/DataStructures/HashMap.h +0 -60
  249. data/src/cxx_supportlib/FileTools/LargeFiles.cpp +0 -41
  250. data/src/cxx_supportlib/FileTools/LargeFiles.h +0 -43
  251. data/src/cxx_supportlib/WebSocketCommandReverseServer.h +0 -975
  252. data/src/cxx_supportlib/oxt/detail/spin_lock_darwin.hpp +0 -75
  253. data/src/cxx_supportlib/oxt/detail/spin_lock_gcc_x86.hpp +0 -85
  254. data/src/cxx_supportlib/oxt/detail/spin_lock_portable.hpp +0 -38
  255. data/src/cxx_supportlib/oxt/detail/spin_lock_pthreads.hpp +0 -111
  256. data/src/cxx_supportlib/vendor-modified/boost/asio/any_completion_executor.hpp +0 -338
  257. data/src/cxx_supportlib/vendor-modified/boost/asio/any_completion_handler.hpp +0 -824
  258. data/src/cxx_supportlib/vendor-modified/boost/asio/any_io_executor.hpp +0 -353
  259. data/src/cxx_supportlib/vendor-modified/boost/asio/append.hpp +0 -67
  260. data/src/cxx_supportlib/vendor-modified/boost/asio/as_tuple.hpp +0 -154
  261. data/src/cxx_supportlib/vendor-modified/boost/asio/associated_allocator.hpp +0 -216
  262. data/src/cxx_supportlib/vendor-modified/boost/asio/associated_cancellation_slot.hpp +0 -223
  263. data/src/cxx_supportlib/vendor-modified/boost/asio/associated_executor.hpp +0 -237
  264. data/src/cxx_supportlib/vendor-modified/boost/asio/associated_immediate_executor.hpp +0 -283
  265. data/src/cxx_supportlib/vendor-modified/boost/asio/associator.hpp +0 -37
  266. data/src/cxx_supportlib/vendor-modified/boost/asio/async_result.hpp +0 -950
  267. data/src/cxx_supportlib/vendor-modified/boost/asio/awaitable.hpp +0 -144
  268. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_datagram_socket.hpp +0 -1364
  269. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_deadline_timer.hpp +0 -712
  270. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_file.hpp +0 -826
  271. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_io_object.hpp +0 -288
  272. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_random_access_file.hpp +0 -691
  273. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_raw_socket.hpp +0 -1358
  274. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_readable_pipe.hpp +0 -628
  275. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_seq_packet_socket.hpp +0 -825
  276. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_serial_port.hpp +0 -989
  277. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_signal_set.hpp +0 -650
  278. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_socket.hpp +0 -1938
  279. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_socket_acceptor.hpp +0 -2710
  280. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_socket_iostream.hpp +0 -333
  281. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_socket_streambuf.hpp +0 -644
  282. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_stream_file.hpp +0 -746
  283. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_stream_socket.hpp +0 -1165
  284. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_streambuf.hpp +0 -452
  285. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_streambuf_fwd.hpp +0 -38
  286. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_waitable_timer.hpp +0 -826
  287. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_writable_pipe.hpp +0 -624
  288. data/src/cxx_supportlib/vendor-modified/boost/asio/bind_allocator.hpp +0 -598
  289. data/src/cxx_supportlib/vendor-modified/boost/asio/bind_cancellation_slot.hpp +0 -615
  290. data/src/cxx_supportlib/vendor-modified/boost/asio/bind_executor.hpp +0 -666
  291. data/src/cxx_supportlib/vendor-modified/boost/asio/bind_immediate_executor.hpp +0 -618
  292. data/src/cxx_supportlib/vendor-modified/boost/asio/buffer.hpp +0 -2755
  293. data/src/cxx_supportlib/vendor-modified/boost/asio/buffer_registration.hpp +0 -320
  294. data/src/cxx_supportlib/vendor-modified/boost/asio/buffered_read_stream.hpp +0 -275
  295. data/src/cxx_supportlib/vendor-modified/boost/asio/buffered_read_stream_fwd.hpp +0 -27
  296. data/src/cxx_supportlib/vendor-modified/boost/asio/buffered_stream.hpp +0 -294
  297. data/src/cxx_supportlib/vendor-modified/boost/asio/buffered_stream_fwd.hpp +0 -27
  298. data/src/cxx_supportlib/vendor-modified/boost/asio/buffered_write_stream.hpp +0 -267
  299. data/src/cxx_supportlib/vendor-modified/boost/asio/buffered_write_stream_fwd.hpp +0 -27
  300. data/src/cxx_supportlib/vendor-modified/boost/asio/buffers_iterator.hpp +0 -523
  301. data/src/cxx_supportlib/vendor-modified/boost/asio/cancel_after.hpp +0 -303
  302. data/src/cxx_supportlib/vendor-modified/boost/asio/cancel_at.hpp +0 -296
  303. data/src/cxx_supportlib/vendor-modified/boost/asio/cancellation_signal.hpp +0 -247
  304. data/src/cxx_supportlib/vendor-modified/boost/asio/cancellation_state.hpp +0 -237
  305. data/src/cxx_supportlib/vendor-modified/boost/asio/cancellation_type.hpp +0 -159
  306. data/src/cxx_supportlib/vendor-modified/boost/asio/co_composed.hpp +0 -1323
  307. data/src/cxx_supportlib/vendor-modified/boost/asio/co_spawn.hpp +0 -525
  308. data/src/cxx_supportlib/vendor-modified/boost/asio/completion_condition.hpp +0 -269
  309. data/src/cxx_supportlib/vendor-modified/boost/asio/compose.hpp +0 -130
  310. data/src/cxx_supportlib/vendor-modified/boost/asio/composed.hpp +0 -415
  311. data/src/cxx_supportlib/vendor-modified/boost/asio/connect.hpp +0 -1348
  312. data/src/cxx_supportlib/vendor-modified/boost/asio/connect_pipe.hpp +0 -85
  313. data/src/cxx_supportlib/vendor-modified/boost/asio/consign.hpp +0 -77
  314. data/src/cxx_supportlib/vendor-modified/boost/asio/coroutine.hpp +0 -330
  315. data/src/cxx_supportlib/vendor-modified/boost/asio/deadline_timer.hpp +0 -40
  316. data/src/cxx_supportlib/vendor-modified/boost/asio/default_completion_token.hpp +0 -91
  317. data/src/cxx_supportlib/vendor-modified/boost/asio/defer.hpp +0 -220
  318. data/src/cxx_supportlib/vendor-modified/boost/asio/deferred.hpp +0 -721
  319. data/src/cxx_supportlib/vendor-modified/boost/asio/detached.hpp +0 -107
  320. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/array.hpp +0 -32
  321. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/array_fwd.hpp +0 -32
  322. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/assert.hpp +0 -32
  323. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/atomic_count.hpp +0 -61
  324. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/base_from_cancellation_state.hpp +0 -166
  325. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/base_from_completion_cond.hpp +0 -71
  326. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/bind_handler.hpp +0 -713
  327. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/blocking_executor_op.hpp +0 -109
  328. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/buffer_resize_guard.hpp +0 -68
  329. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/buffer_sequence_adapter.hpp +0 -839
  330. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/buffered_stream_storage.hpp +0 -128
  331. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/call_stack.hpp +0 -127
  332. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/chrono.hpp +0 -47
  333. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/chrono_time_traits.hpp +0 -192
  334. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/completion_handler.hpp +0 -90
  335. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/completion_message.hpp +0 -129
  336. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/completion_payload.hpp +0 -222
  337. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/completion_payload_handler.hpp +0 -81
  338. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/composed_work.hpp +0 -254
  339. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/concurrency_hint.hpp +0 -94
  340. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/conditionally_enabled_event.hpp +0 -122
  341. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/conditionally_enabled_mutex.hpp +0 -151
  342. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/config.hpp +0 -1413
  343. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/consuming_buffers.hpp +0 -445
  344. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/cstddef.hpp +0 -29
  345. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/cstdint.hpp +0 -42
  346. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/date_time_fwd.hpp +0 -34
  347. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/deadline_timer_service.hpp +0 -341
  348. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/dependent_type.hpp +0 -38
  349. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/descriptor_ops.hpp +0 -181
  350. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/descriptor_read_op.hpp +0 -190
  351. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/descriptor_write_op.hpp +0 -189
  352. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/dev_poll_reactor.hpp +0 -249
  353. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/epoll_reactor.hpp +0 -297
  354. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/event.hpp +0 -48
  355. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/eventfd_select_interrupter.hpp +0 -85
  356. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/exception.hpp +0 -31
  357. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/executor_function.hpp +0 -154
  358. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/executor_op.hpp +0 -86
  359. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/fd_set_adapter.hpp +0 -41
  360. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/fenced_block.hpp +0 -42
  361. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/functional.hpp +0 -35
  362. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/future.hpp +0 -32
  363. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/global.hpp +0 -52
  364. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/handler_alloc_helpers.hpp +0 -123
  365. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/handler_cont_helpers.hpp +0 -45
  366. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/handler_tracking.hpp +0 -268
  367. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/handler_type_requirements.hpp +0 -555
  368. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/handler_work.hpp +0 -513
  369. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/hash_map.hpp +0 -333
  370. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/buffer_sequence_adapter.ipp +0 -120
  371. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/descriptor_ops.ipp +0 -996
  372. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/dev_poll_reactor.hpp +0 -113
  373. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/dev_poll_reactor.ipp +0 -471
  374. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/epoll_reactor.hpp +0 -111
  375. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/epoll_reactor.ipp +0 -828
  376. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/eventfd_select_interrupter.ipp +0 -173
  377. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/handler_tracking.ipp +0 -400
  378. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/io_uring_descriptor_service.ipp +0 -207
  379. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/io_uring_file_service.ipp +0 -142
  380. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/io_uring_service.hpp +0 -114
  381. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/io_uring_service.ipp +0 -916
  382. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/io_uring_socket_service_base.ipp +0 -251
  383. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/kqueue_reactor.hpp +0 -115
  384. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/kqueue_reactor.ipp +0 -610
  385. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/null_event.ipp +0 -76
  386. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/pipe_select_interrupter.ipp +0 -131
  387. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/posix_event.ipp +0 -65
  388. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/posix_mutex.ipp +0 -48
  389. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/posix_serial_port_service.ipp +0 -170
  390. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/posix_thread.ipp +0 -86
  391. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/posix_tss_ptr.ipp +0 -48
  392. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/reactive_descriptor_service.ipp +0 -234
  393. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/reactive_socket_service_base.ipp +0 -314
  394. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/resolver_service_base.ipp +0 -160
  395. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/scheduler.ipp +0 -677
  396. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/select_reactor.hpp +0 -126
  397. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/select_reactor.ipp +0 -402
  398. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/service_registry.hpp +0 -95
  399. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/service_registry.ipp +0 -199
  400. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/signal_set_service.ipp +0 -828
  401. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/socket_ops.ipp +0 -4046
  402. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/socket_select_interrupter.ipp +0 -187
  403. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/strand_executor_service.hpp +0 -348
  404. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/strand_executor_service.ipp +0 -160
  405. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/strand_service.hpp +0 -88
  406. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/strand_service.ipp +0 -204
  407. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/thread_context.ipp +0 -37
  408. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/throw_error.ipp +0 -51
  409. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/timer_queue_ptime.ipp +0 -99
  410. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/timer_queue_set.ipp +0 -103
  411. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/initiate_defer.hpp +0 -209
  412. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/initiate_dispatch.hpp +0 -195
  413. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/initiate_post.hpp +0 -209
  414. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/initiation_base.hpp +0 -64
  415. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_control.hpp +0 -86
  416. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_object_impl.hpp +0 -179
  417. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_descriptor_read_at_op.hpp +0 -197
  418. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_descriptor_read_op.hpp +0 -192
  419. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_descriptor_service.hpp +0 -689
  420. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_descriptor_write_at_op.hpp +0 -191
  421. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_descriptor_write_op.hpp +0 -187
  422. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_file_service.hpp +0 -263
  423. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_null_buffers_op.hpp +0 -116
  424. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_operation.hpp +0 -86
  425. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_service.hpp +0 -321
  426. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_socket_accept_op.hpp +0 -282
  427. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_socket_connect_op.hpp +0 -142
  428. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_socket_recv_op.hpp +0 -207
  429. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_socket_recvfrom_op.hpp +0 -208
  430. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_socket_recvmsg_op.hpp +0 -194
  431. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_socket_send_op.hpp +0 -193
  432. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_socket_sendto_op.hpp +0 -196
  433. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_socket_service.hpp +0 -631
  434. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_socket_service_base.hpp +0 -665
  435. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/io_uring_wait_op.hpp +0 -114
  436. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/is_buffer_sequence.hpp +0 -298
  437. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/is_executor.hpp +0 -128
  438. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/keyword_tss_ptr.hpp +0 -72
  439. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/kqueue_reactor.hpp +0 -273
  440. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/limits.hpp +0 -21
  441. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/local_free_on_block_exit.hpp +0 -61
  442. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/memory.hpp +0 -128
  443. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/mutex.hpp +0 -48
  444. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/non_const_lvalue.hpp +0 -45
  445. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/noncopyable.hpp +0 -45
  446. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/null_event.hpp +0 -108
  447. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/null_fenced_block.hpp +0 -49
  448. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/null_global.hpp +0 -61
  449. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/null_mutex.hpp +0 -62
  450. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/null_reactor.hpp +0 -85
  451. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/null_signal_blocker.hpp +0 -71
  452. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/null_socket_service.hpp +0 -521
  453. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/null_static_mutex.hpp +0 -62
  454. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/null_thread.hpp +0 -69
  455. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/null_tss_ptr.hpp +0 -70
  456. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/object_pool.hpp +0 -173
  457. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/op_queue.hpp +0 -164
  458. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/operation.hpp +0 -40
  459. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/pipe_select_interrupter.hpp +0 -91
  460. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/pop_options.hpp +0 -157
  461. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/posix_event.hpp +0 -177
  462. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/posix_fd_set_adapter.hpp +0 -120
  463. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/posix_global.hpp +0 -82
  464. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/posix_mutex.hpp +0 -78
  465. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/posix_serial_port_service.hpp +0 -251
  466. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/posix_signal_blocker.hpp +0 -87
  467. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/posix_static_mutex.hpp +0 -66
  468. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/posix_thread.hpp +0 -111
  469. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/posix_tss_ptr.hpp +0 -81
  470. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/push_options.hpp +0 -228
  471. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/reactive_descriptor_service.hpp +0 -572
  472. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/reactive_null_buffers_op.hpp +0 -133
  473. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/reactive_socket_accept_op.hpp +0 -325
  474. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/reactive_socket_connect_op.hpp +0 -164
  475. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/reactive_socket_recv_op.hpp +0 -199
  476. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/reactive_socket_recvfrom_op.hpp +0 -205
  477. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/reactive_socket_recvmsg_op.hpp +0 -186
  478. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/reactive_socket_send_op.hpp +0 -202
  479. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/reactive_socket_sendto_op.hpp +0 -196
  480. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/reactive_socket_service.hpp +0 -635
  481. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/reactive_socket_service_base.hpp +0 -757
  482. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/reactive_wait_op.hpp +0 -133
  483. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/reactor.hpp +0 -56
  484. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/reactor_op.hpp +0 -73
  485. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/reactor_op_queue.hpp +0 -214
  486. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/recycling_allocator.hpp +0 -116
  487. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/regex_fwd.hpp +0 -35
  488. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/resolve_endpoint_op.hpp +0 -142
  489. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/resolve_op.hpp +0 -47
  490. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/resolve_query_op.hpp +0 -152
  491. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/resolver_service.hpp +0 -149
  492. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/resolver_service_base.hpp +0 -160
  493. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/scheduler.hpp +0 -243
  494. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/scheduler_operation.hpp +0 -80
  495. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/scheduler_task.hpp +0 -51
  496. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/scheduler_thread_info.hpp +0 -42
  497. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/scoped_lock.hpp +0 -103
  498. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/scoped_ptr.hpp +0 -89
  499. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/select_interrupter.hpp +0 -48
  500. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/select_reactor.hpp +0 -293
  501. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/service_registry.hpp +0 -165
  502. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/signal_blocker.hpp +0 -46
  503. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/signal_handler.hpp +0 -92
  504. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/signal_init.hpp +0 -49
  505. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/signal_op.hpp +0 -55
  506. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/signal_set_service.hpp +0 -294
  507. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/socket_holder.hpp +0 -100
  508. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/socket_ops.hpp +0 -377
  509. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/socket_option.hpp +0 -318
  510. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/socket_select_interrupter.hpp +0 -93
  511. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/socket_types.hpp +0 -429
  512. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/source_location.hpp +0 -47
  513. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/static_mutex.hpp +0 -52
  514. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/std_event.hpp +0 -185
  515. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/std_fenced_block.hpp +0 -59
  516. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/std_global.hpp +0 -67
  517. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/std_mutex.hpp +0 -70
  518. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/std_static_mutex.hpp +0 -78
  519. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/std_thread.hpp +0 -68
  520. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/strand_executor_service.hpp +0 -175
  521. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/strand_service.hpp +0 -146
  522. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/string_view.hpp +0 -49
  523. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/thread.hpp +0 -60
  524. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/thread_context.hpp +0 -53
  525. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/thread_group.hpp +0 -101
  526. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/thread_info_base.hpp +0 -262
  527. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/throw_error.hpp +0 -64
  528. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/throw_exception.hpp +0 -57
  529. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/timed_cancel_op.hpp +0 -363
  530. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/timer_queue.hpp +0 -391
  531. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/timer_queue_base.hpp +0 -70
  532. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/timer_queue_ptime.hpp +0 -105
  533. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/timer_queue_set.hpp +0 -68
  534. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/timer_scheduler.hpp +0 -37
  535. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/timer_scheduler_fwd.hpp +0 -44
  536. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/tss_ptr.hpp +0 -71
  537. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/type_traits.hpp +0 -180
  538. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/utility.hpp +0 -85
  539. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/wait_handler.hpp +0 -92
  540. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/wait_op.hpp +0 -51
  541. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/winsock_init.hpp +0 -130
  542. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/work_dispatcher.hpp +0 -145
  543. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/wrapped_handler.hpp +0 -197
  544. data/src/cxx_supportlib/vendor-modified/boost/asio/dispatch.hpp +0 -199
  545. data/src/cxx_supportlib/vendor-modified/boost/asio/error.hpp +0 -390
  546. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/allocator.hpp +0 -280
  547. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/any_executor.hpp +0 -1935
  548. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/bad_executor.hpp +0 -48
  549. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/blocking.hpp +0 -1362
  550. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/blocking_adaptation.hpp +0 -1082
  551. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/context.hpp +0 -193
  552. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/context_as.hpp +0 -192
  553. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/executor.hpp +0 -118
  554. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/impl/bad_executor.ipp +0 -42
  555. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/invocable_archetype.hpp +0 -45
  556. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/mapping.hpp +0 -1004
  557. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/occupancy.hpp +0 -186
  558. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/outstanding_work.hpp +0 -755
  559. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/prefer_only.hpp +0 -330
  560. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/relationship.hpp +0 -753
  561. data/src/cxx_supportlib/vendor-modified/boost/asio/execution.hpp +0 -33
  562. data/src/cxx_supportlib/vendor-modified/boost/asio/execution_context.hpp +0 -390
  563. data/src/cxx_supportlib/vendor-modified/boost/asio/executor.hpp +0 -365
  564. data/src/cxx_supportlib/vendor-modified/boost/asio/executor_work_guard.hpp +0 -364
  565. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/append.hpp +0 -38
  566. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/as_single.hpp +0 -134
  567. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/as_tuple.hpp +0 -38
  568. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/awaitable_operators.hpp +0 -538
  569. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/basic_channel.hpp +0 -516
  570. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/basic_concurrent_channel.hpp +0 -516
  571. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/cancellation_condition.hpp +0 -154
  572. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/channel.hpp +0 -72
  573. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/channel_error.hpp +0 -88
  574. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/channel_traits.hpp +0 -303
  575. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/co_composed.hpp +0 -35
  576. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/co_spawn.hpp +0 -189
  577. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/concurrent_channel.hpp +0 -72
  578. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/coro.hpp +0 -295
  579. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/coro_traits.hpp +0 -230
  580. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/deferred.hpp +0 -38
  581. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/channel_operation.hpp +0 -363
  582. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/channel_receive_op.hpp +0 -128
  583. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/channel_send_functions.hpp +0 -202
  584. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/channel_send_op.hpp +0 -149
  585. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/channel_service.hpp +0 -681
  586. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/coro_completion_handler.hpp +0 -171
  587. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/coro_promise_allocator.hpp +0 -142
  588. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/has_signature.hpp +0 -56
  589. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/impl/channel_service.hpp +0 -625
  590. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/partial_promise.hpp +0 -199
  591. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/impl/as_single.hpp +0 -183
  592. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/impl/channel_error.ipp +0 -63
  593. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/impl/coro.hpp +0 -1224
  594. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/impl/parallel_group.hpp +0 -790
  595. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/impl/promise.hpp +0 -257
  596. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/impl/use_coro.hpp +0 -216
  597. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/impl/use_promise.hpp +0 -68
  598. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/parallel_group.hpp +0 -457
  599. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/prepend.hpp +0 -38
  600. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/promise.hpp +0 -226
  601. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/use_coro.hpp +0 -191
  602. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/use_promise.hpp +0 -113
  603. data/src/cxx_supportlib/vendor-modified/boost/asio/file_base.hpp +0 -168
  604. data/src/cxx_supportlib/vendor-modified/boost/asio/generic/basic_endpoint.hpp +0 -191
  605. data/src/cxx_supportlib/vendor-modified/boost/asio/generic/datagram_protocol.hpp +0 -125
  606. data/src/cxx_supportlib/vendor-modified/boost/asio/generic/detail/endpoint.hpp +0 -135
  607. data/src/cxx_supportlib/vendor-modified/boost/asio/generic/detail/impl/endpoint.ipp +0 -112
  608. data/src/cxx_supportlib/vendor-modified/boost/asio/generic/raw_protocol.hpp +0 -123
  609. data/src/cxx_supportlib/vendor-modified/boost/asio/generic/seq_packet_protocol.hpp +0 -124
  610. data/src/cxx_supportlib/vendor-modified/boost/asio/generic/stream_protocol.hpp +0 -129
  611. data/src/cxx_supportlib/vendor-modified/boost/asio/handler_continuation_hook.hpp +0 -56
  612. data/src/cxx_supportlib/vendor-modified/boost/asio/high_resolution_timer.hpp +0 -41
  613. data/src/cxx_supportlib/vendor-modified/boost/asio/immediate.hpp +0 -144
  614. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/any_completion_executor.ipp +0 -128
  615. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/any_io_executor.ipp +0 -136
  616. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/append.hpp +0 -171
  617. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/as_tuple.hpp +0 -278
  618. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/awaitable.hpp +0 -1198
  619. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/buffered_read_stream.hpp +0 -406
  620. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/buffered_write_stream.hpp +0 -386
  621. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/cancel_after.hpp +0 -270
  622. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/cancel_at.hpp +0 -270
  623. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/cancellation_signal.ipp +0 -98
  624. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/co_spawn.hpp +0 -459
  625. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/connect.hpp +0 -705
  626. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/connect_pipe.hpp +0 -75
  627. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/connect_pipe.ipp +0 -151
  628. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/consign.hpp +0 -146
  629. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/deferred.hpp +0 -149
  630. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/detached.hpp +0 -79
  631. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/error.ipp +0 -130
  632. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/execution_context.hpp +0 -79
  633. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/execution_context.ipp +0 -84
  634. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/executor.hpp +0 -319
  635. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/executor.ipp +0 -45
  636. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/io_context.hpp +0 -435
  637. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/io_context.ipp +0 -178
  638. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/multiple_exceptions.ipp +0 -47
  639. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/prepend.hpp +0 -172
  640. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/read.hpp +0 -904
  641. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/read_at.hpp +0 -564
  642. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/read_until.hpp +0 -2670
  643. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/redirect_error.hpp +0 -289
  644. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/serial_port_base.hpp +0 -61
  645. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/serial_port_base.ipp +0 -556
  646. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/spawn.hpp +0 -1402
  647. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/src.hpp +0 -93
  648. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/system_context.hpp +0 -36
  649. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/system_context.ipp +0 -94
  650. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/system_executor.hpp +0 -181
  651. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/thread_pool.hpp +0 -279
  652. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/thread_pool.ipp +0 -144
  653. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/use_awaitable.hpp +0 -303
  654. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/use_future.hpp +0 -709
  655. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/write.hpp +0 -782
  656. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/write_at.hpp +0 -482
  657. data/src/cxx_supportlib/vendor-modified/boost/asio/io_context.hpp +0 -1507
  658. data/src/cxx_supportlib/vendor-modified/boost/asio/io_context_strand.hpp +0 -398
  659. data/src/cxx_supportlib/vendor-modified/boost/asio/io_service.hpp +0 -35
  660. data/src/cxx_supportlib/vendor-modified/boost/asio/io_service_strand.hpp +0 -20
  661. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/address.hpp +0 -283
  662. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/address_v4.hpp +0 -423
  663. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/address_v4_iterator.hpp +0 -158
  664. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/address_v4_range.hpp +0 -130
  665. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/address_v6.hpp +0 -409
  666. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/address_v6_iterator.hpp +0 -180
  667. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/address_v6_range.hpp +0 -126
  668. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/bad_address_cast.hpp +0 -65
  669. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/basic_endpoint.hpp +0 -284
  670. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/basic_resolver.hpp +0 -1114
  671. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/basic_resolver_entry.hpp +0 -115
  672. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/basic_resolver_iterator.hpp +0 -190
  673. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/basic_resolver_query.hpp +0 -262
  674. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/basic_resolver_results.hpp +0 -309
  675. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/detail/endpoint.hpp +0 -143
  676. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/detail/impl/endpoint.ipp +0 -197
  677. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/detail/socket_option.hpp +0 -568
  678. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/host_name.hpp +0 -44
  679. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/icmp.hpp +0 -117
  680. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/impl/address.hpp +0 -69
  681. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/impl/address.ipp +0 -237
  682. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/impl/address_v4.hpp +0 -69
  683. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/impl/address_v4.ipp +0 -208
  684. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/impl/address_v6.hpp +0 -69
  685. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/impl/address_v6.ipp +0 -344
  686. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/impl/basic_endpoint.hpp +0 -45
  687. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/impl/host_name.ipp +0 -56
  688. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/impl/network_v4.hpp +0 -56
  689. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/impl/network_v4.ipp +0 -220
  690. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/impl/network_v6.hpp +0 -55
  691. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/impl/network_v6.ipp +0 -189
  692. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/multicast.hpp +0 -193
  693. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/network_v4.hpp +0 -259
  694. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/network_v6.hpp +0 -233
  695. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/resolver_base.hpp +0 -131
  696. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/resolver_query_base.hpp +0 -45
  697. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/tcp.hpp +0 -157
  698. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/udp.hpp +0 -113
  699. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/unicast.hpp +0 -72
  700. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/v6_only.hpp +0 -71
  701. data/src/cxx_supportlib/vendor-modified/boost/asio/is_applicable_property.hpp +0 -63
  702. data/src/cxx_supportlib/vendor-modified/boost/asio/is_contiguous_iterator.hpp +0 -47
  703. data/src/cxx_supportlib/vendor-modified/boost/asio/is_executor.hpp +0 -48
  704. data/src/cxx_supportlib/vendor-modified/boost/asio/is_read_buffered.hpp +0 -61
  705. data/src/cxx_supportlib/vendor-modified/boost/asio/is_write_buffered.hpp +0 -61
  706. data/src/cxx_supportlib/vendor-modified/boost/asio/local/basic_endpoint.hpp +0 -245
  707. data/src/cxx_supportlib/vendor-modified/boost/asio/local/connect_pair.hpp +0 -103
  708. data/src/cxx_supportlib/vendor-modified/boost/asio/local/datagram_protocol.hpp +0 -82
  709. data/src/cxx_supportlib/vendor-modified/boost/asio/local/detail/endpoint.hpp +0 -141
  710. data/src/cxx_supportlib/vendor-modified/boost/asio/local/detail/impl/endpoint.ipp +0 -133
  711. data/src/cxx_supportlib/vendor-modified/boost/asio/local/seq_packet_protocol.hpp +0 -86
  712. data/src/cxx_supportlib/vendor-modified/boost/asio/local/stream_protocol.hpp +0 -92
  713. data/src/cxx_supportlib/vendor-modified/boost/asio/multiple_exceptions.hpp +0 -54
  714. data/src/cxx_supportlib/vendor-modified/boost/asio/packaged_task.hpp +0 -68
  715. data/src/cxx_supportlib/vendor-modified/boost/asio/placeholders.hpp +0 -83
  716. data/src/cxx_supportlib/vendor-modified/boost/asio/posix/basic_descriptor.hpp +0 -775
  717. data/src/cxx_supportlib/vendor-modified/boost/asio/posix/basic_stream_descriptor.hpp +0 -561
  718. data/src/cxx_supportlib/vendor-modified/boost/asio/posix/descriptor.hpp +0 -39
  719. data/src/cxx_supportlib/vendor-modified/boost/asio/posix/descriptor_base.hpp +0 -92
  720. data/src/cxx_supportlib/vendor-modified/boost/asio/posix/stream_descriptor.hpp +0 -39
  721. data/src/cxx_supportlib/vendor-modified/boost/asio/post.hpp +0 -215
  722. data/src/cxx_supportlib/vendor-modified/boost/asio/prefer.hpp +0 -581
  723. data/src/cxx_supportlib/vendor-modified/boost/asio/prepend.hpp +0 -68
  724. data/src/cxx_supportlib/vendor-modified/boost/asio/query.hpp +0 -315
  725. data/src/cxx_supportlib/vendor-modified/boost/asio/random_access_file.hpp +0 -37
  726. data/src/cxx_supportlib/vendor-modified/boost/asio/read.hpp +0 -1549
  727. data/src/cxx_supportlib/vendor-modified/boost/asio/read_at.hpp +0 -830
  728. data/src/cxx_supportlib/vendor-modified/boost/asio/read_until.hpp +0 -3204
  729. data/src/cxx_supportlib/vendor-modified/boost/asio/readable_pipe.hpp +0 -37
  730. data/src/cxx_supportlib/vendor-modified/boost/asio/recycling_allocator.hpp +0 -140
  731. data/src/cxx_supportlib/vendor-modified/boost/asio/redirect_error.hpp +0 -106
  732. data/src/cxx_supportlib/vendor-modified/boost/asio/registered_buffer.hpp +0 -346
  733. data/src/cxx_supportlib/vendor-modified/boost/asio/require.hpp +0 -437
  734. data/src/cxx_supportlib/vendor-modified/boost/asio/require_concept.hpp +0 -347
  735. data/src/cxx_supportlib/vendor-modified/boost/asio/serial_port.hpp +0 -38
  736. data/src/cxx_supportlib/vendor-modified/boost/asio/serial_port_base.hpp +0 -169
  737. data/src/cxx_supportlib/vendor-modified/boost/asio/signal_set.hpp +0 -30
  738. data/src/cxx_supportlib/vendor-modified/boost/asio/signal_set_base.hpp +0 -173
  739. data/src/cxx_supportlib/vendor-modified/boost/asio/socket_base.hpp +0 -561
  740. data/src/cxx_supportlib/vendor-modified/boost/asio/spawn.hpp +0 -873
  741. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/context.hpp +0 -764
  742. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/context_base.hpp +0 -211
  743. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/detail/buffered_handshake_op.hpp +0 -121
  744. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/detail/engine.hpp +0 -171
  745. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/detail/handshake_op.hpp +0 -69
  746. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/detail/impl/engine.ipp +0 -379
  747. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/detail/impl/openssl_init.ipp +0 -171
  748. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/detail/io.hpp +0 -378
  749. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/detail/openssl_init.hpp +0 -103
  750. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/detail/openssl_types.hpp +0 -34
  751. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/detail/password_callback.hpp +0 -68
  752. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/detail/read_op.hpp +0 -74
  753. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/detail/shutdown_op.hpp +0 -71
  754. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/detail/stream_core.hpp +0 -219
  755. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/detail/verify_callback.hpp +0 -64
  756. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/detail/write_op.hpp +0 -78
  757. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/error.hpp +0 -129
  758. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/host_name_verification.hpp +0 -92
  759. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/impl/context.hpp +0 -69
  760. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/impl/context.ipp +0 -1324
  761. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/impl/error.ipp +0 -126
  762. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/impl/host_name_verification.ipp +0 -75
  763. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/impl/rfc2818_verification.ipp +0 -166
  764. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/impl/src.hpp +0 -29
  765. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/rfc2818_verification.hpp +0 -100
  766. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/stream.hpp +0 -1044
  767. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/stream_base.hpp +0 -54
  768. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/verify_context.hpp +0 -69
  769. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/verify_mode.hpp +0 -65
  770. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl.hpp +0 -28
  771. data/src/cxx_supportlib/vendor-modified/boost/asio/static_thread_pool.hpp +0 -33
  772. data/src/cxx_supportlib/vendor-modified/boost/asio/steady_timer.hpp +0 -39
  773. data/src/cxx_supportlib/vendor-modified/boost/asio/strand.hpp +0 -559
  774. data/src/cxx_supportlib/vendor-modified/boost/asio/stream_file.hpp +0 -37
  775. data/src/cxx_supportlib/vendor-modified/boost/asio/streambuf.hpp +0 -35
  776. data/src/cxx_supportlib/vendor-modified/boost/asio/system_context.hpp +0 -92
  777. data/src/cxx_supportlib/vendor-modified/boost/asio/system_executor.hpp +0 -673
  778. data/src/cxx_supportlib/vendor-modified/boost/asio/system_timer.hpp +0 -39
  779. data/src/cxx_supportlib/vendor-modified/boost/asio/this_coro.hpp +0 -269
  780. data/src/cxx_supportlib/vendor-modified/boost/asio/thread_pool.hpp +0 -965
  781. data/src/cxx_supportlib/vendor-modified/boost/asio/time_traits.hpp +0 -88
  782. data/src/cxx_supportlib/vendor-modified/boost/asio/traits/equality_comparable.hpp +0 -102
  783. data/src/cxx_supportlib/vendor-modified/boost/asio/traits/execute_member.hpp +0 -106
  784. data/src/cxx_supportlib/vendor-modified/boost/asio/traits/prefer_free.hpp +0 -106
  785. data/src/cxx_supportlib/vendor-modified/boost/asio/traits/prefer_member.hpp +0 -106
  786. data/src/cxx_supportlib/vendor-modified/boost/asio/traits/query_free.hpp +0 -106
  787. data/src/cxx_supportlib/vendor-modified/boost/asio/traits/query_member.hpp +0 -106
  788. data/src/cxx_supportlib/vendor-modified/boost/asio/traits/query_static_constexpr_member.hpp +0 -103
  789. data/src/cxx_supportlib/vendor-modified/boost/asio/traits/require_concept_free.hpp +0 -106
  790. data/src/cxx_supportlib/vendor-modified/boost/asio/traits/require_concept_member.hpp +0 -106
  791. data/src/cxx_supportlib/vendor-modified/boost/asio/traits/require_free.hpp +0 -106
  792. data/src/cxx_supportlib/vendor-modified/boost/asio/traits/require_member.hpp +0 -106
  793. data/src/cxx_supportlib/vendor-modified/boost/asio/traits/static_query.hpp +0 -104
  794. data/src/cxx_supportlib/vendor-modified/boost/asio/traits/static_require.hpp +0 -117
  795. data/src/cxx_supportlib/vendor-modified/boost/asio/traits/static_require_concept.hpp +0 -118
  796. data/src/cxx_supportlib/vendor-modified/boost/asio/ts/buffer.hpp +0 -24
  797. data/src/cxx_supportlib/vendor-modified/boost/asio/ts/executor.hpp +0 -35
  798. data/src/cxx_supportlib/vendor-modified/boost/asio/ts/internet.hpp +0 -40
  799. data/src/cxx_supportlib/vendor-modified/boost/asio/ts/io_context.hpp +0 -20
  800. data/src/cxx_supportlib/vendor-modified/boost/asio/ts/net.hpp +0 -26
  801. data/src/cxx_supportlib/vendor-modified/boost/asio/ts/netfwd.hpp +0 -238
  802. data/src/cxx_supportlib/vendor-modified/boost/asio/ts/socket.hpp +0 -27
  803. data/src/cxx_supportlib/vendor-modified/boost/asio/ts/timer.hpp +0 -26
  804. data/src/cxx_supportlib/vendor-modified/boost/asio/unyield.hpp +0 -21
  805. data/src/cxx_supportlib/vendor-modified/boost/asio/use_awaitable.hpp +0 -163
  806. data/src/cxx_supportlib/vendor-modified/boost/asio/use_future.hpp +0 -161
  807. data/src/cxx_supportlib/vendor-modified/boost/asio/uses_executor.hpp +0 -69
  808. data/src/cxx_supportlib/vendor-modified/boost/asio/version.hpp +0 -23
  809. data/src/cxx_supportlib/vendor-modified/boost/asio/wait_traits.hpp +0 -58
  810. data/src/cxx_supportlib/vendor-modified/boost/asio/writable_pipe.hpp +0 -37
  811. data/src/cxx_supportlib/vendor-modified/boost/asio/write.hpp +0 -1528
  812. data/src/cxx_supportlib/vendor-modified/boost/asio/write_at.hpp +0 -843
  813. data/src/cxx_supportlib/vendor-modified/boost/asio/yield.hpp +0 -23
  814. data/src/cxx_supportlib/vendor-modified/boost/asio.hpp +0 -195
  815. data/src/cxx_supportlib/vendor-modified/boost/optional/detail/old_optional_implementation.hpp +0 -1059
  816. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/operator_bool.hpp +0 -64
  817. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/requires_cxx11.hpp +0 -23
  818. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_forward.hpp +0 -52
  819. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_nullptr_t.hpp +0 -45
  820. data/src/cxx_supportlib/vendor-modified/websocketpp/COPYING +0 -145
  821. data/src/cxx_supportlib/vendor-modified/websocketpp/changelog.md +0 -444
  822. data/src/cxx_supportlib/vendor-modified/websocketpp/readme.md +0 -49
  823. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/base64/base64.hpp +0 -178
  824. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/client.hpp +0 -33
  825. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/close.hpp +0 -353
  826. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/asio.hpp +0 -141
  827. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/asio_ssl.hpp +0 -39
  828. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/chrono.hpp +0 -68
  829. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/connection_hdl.hpp +0 -52
  830. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/cpp11.hpp +0 -162
  831. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/functional.hpp +0 -100
  832. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/md5.hpp +0 -448
  833. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/memory.hpp +0 -88
  834. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/network.hpp +0 -106
  835. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/platforms.hpp +0 -46
  836. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/random.hpp +0 -82
  837. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/regex.hpp +0 -59
  838. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/stdint.hpp +0 -73
  839. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/system_error.hpp +0 -84
  840. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/thread.hpp +0 -88
  841. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/time.hpp +0 -56
  842. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/type_traits.hpp +0 -65
  843. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/concurrency/basic.hpp +0 -46
  844. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/concurrency/none.hpp +0 -80
  845. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/config/asio.hpp +0 -77
  846. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/config/asio_client.hpp +0 -77
  847. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/config/asio_no_tls.hpp +0 -73
  848. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/config/asio_no_tls_client.hpp +0 -73
  849. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/config/boost_config.hpp +0 -72
  850. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/config/core.hpp +0 -297
  851. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/config/core_client.hpp +0 -294
  852. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/config/debug.hpp +0 -286
  853. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/config/debug_asio.hpp +0 -77
  854. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/config/debug_asio_no_tls.hpp +0 -73
  855. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/config/minimal_client.hpp +0 -72
  856. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/config/minimal_server.hpp +0 -312
  857. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/connection.hpp +0 -1642
  858. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/connection_base.hpp +0 -38
  859. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/endpoint.hpp +0 -700
  860. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/endpoint_base.hpp +0 -38
  861. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/error.hpp +0 -277
  862. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/extensions/extension.hpp +0 -102
  863. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/extensions/permessage_deflate/disabled.hpp +0 -129
  864. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/extensions/permessage_deflate/enabled.hpp +0 -817
  865. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/frame.hpp +0 -853
  866. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/http/constants.hpp +0 -308
  867. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/http/impl/parser.hpp +0 -200
  868. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/http/impl/request.hpp +0 -191
  869. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/http/impl/response.hpp +0 -266
  870. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/http/parser.hpp +0 -629
  871. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/http/request.hpp +0 -124
  872. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/http/response.hpp +0 -188
  873. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/impl/connection_impl.hpp +0 -2375
  874. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/impl/endpoint_impl.hpp +0 -269
  875. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/impl/utilities_impl.hpp +0 -87
  876. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/logger/basic.hpp +0 -199
  877. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/logger/levels.hpp +0 -203
  878. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/logger/stub.hpp +0 -119
  879. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/logger/syslog.hpp +0 -146
  880. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/message_buffer/alloc.hpp +0 -105
  881. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/message_buffer/message.hpp +0 -340
  882. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/message_buffer/pool.hpp +0 -229
  883. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/processors/base.hpp +0 -299
  884. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/processors/hybi00.hpp +0 -462
  885. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/processors/hybi07.hpp +0 -78
  886. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/processors/hybi08.hpp +0 -83
  887. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/processors/hybi13.hpp +0 -1072
  888. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/processors/processor.hpp +0 -407
  889. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/random/none.hpp +0 -60
  890. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/random/random_device.hpp +0 -80
  891. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/roles/client_endpoint.hpp +0 -173
  892. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/roles/server_endpoint.hpp +0 -195
  893. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/server.hpp +0 -33
  894. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/sha1/sha1.hpp +0 -189
  895. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/asio/base.hpp +0 -232
  896. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/asio/connection.hpp +0 -1197
  897. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/asio/endpoint.hpp +0 -1182
  898. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/asio/security/base.hpp +0 -159
  899. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/asio/security/none.hpp +0 -372
  900. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/asio/security/tls.hpp +0 -474
  901. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/base/connection.hpp +0 -238
  902. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/base/endpoint.hpp +0 -77
  903. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/debug/base.hpp +0 -104
  904. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/debug/connection.hpp +0 -412
  905. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/debug/endpoint.hpp +0 -140
  906. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/iostream/base.hpp +0 -133
  907. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/iostream/connection.hpp +0 -714
  908. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/iostream/endpoint.hpp +0 -222
  909. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/stub/base.hpp +0 -95
  910. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/stub/connection.hpp +0 -286
  911. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/transport/stub/endpoint.hpp +0 -140
  912. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/uri.hpp +0 -356
  913. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/utf8_validator.hpp +0 -154
  914. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/utilities.hpp +0 -180
  915. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/version.hpp +0 -61
@@ -1,3204 +0,0 @@
1
- //
2
- // read_until.hpp
3
- // ~~~~~~~~~~~~~~
4
- //
5
- // Copyright (c) 2003-2024 Christopher M. Kohlhoff (chris at kohlhoff dot com)
6
- //
7
- // Distributed under the Boost Software License, Version 1.0. (See accompanying
8
- // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
9
- //
10
-
11
- #ifndef BOOST_ASIO_READ_UNTIL_HPP
12
- #define BOOST_ASIO_READ_UNTIL_HPP
13
-
14
- #if defined(_MSC_VER) && (_MSC_VER >= 1200)
15
- # pragma once
16
- #endif // defined(_MSC_VER) && (_MSC_VER >= 1200)
17
-
18
- #include <boost/asio/detail/config.hpp>
19
- #include <cstddef>
20
- #include <string>
21
- #include <boost/asio/async_result.hpp>
22
- #include <boost/asio/buffer.hpp>
23
- #include <boost/asio/detail/regex_fwd.hpp>
24
- #include <boost/asio/detail/string_view.hpp>
25
- #include <boost/asio/detail/type_traits.hpp>
26
- #include <boost/asio/error.hpp>
27
-
28
- #if !defined(BOOST_ASIO_NO_EXTENSIONS)
29
- # include <boost/asio/basic_streambuf_fwd.hpp>
30
- #endif // !defined(BOOST_ASIO_NO_EXTENSIONS)
31
-
32
- #include <boost/asio/detail/push_options.hpp>
33
-
34
- namespace boost {
35
- namespace asio {
36
- namespace detail {
37
-
38
- char (&has_result_type_helper(...))[2];
39
-
40
- template <typename T>
41
- char has_result_type_helper(T*, typename T::result_type* = 0);
42
-
43
- template <typename T>
44
- struct has_result_type
45
- {
46
- enum { value = (sizeof((has_result_type_helper)((T*)(0))) == 1) };
47
- };
48
-
49
- #if !defined(BOOST_ASIO_NO_DYNAMIC_BUFFER_V1)
50
- template <typename> class initiate_async_read_until_delim_v1;
51
- template <typename> class initiate_async_read_until_delim_string_v1;
52
- #if defined(BOOST_ASIO_HAS_BOOST_REGEX)
53
- template <typename> class initiate_async_read_until_expr_v1;
54
- #endif // defined(BOOST_ASIO_HAS_BOOST_REGEX)
55
- template <typename> class initiate_async_read_until_match_v1;
56
- #endif // !defined(BOOST_ASIO_NO_DYNAMIC_BUFFER_V1)
57
- template <typename> class initiate_async_read_until_delim_v2;
58
- template <typename> class initiate_async_read_until_delim_string_v2;
59
- #if defined(BOOST_ASIO_HAS_BOOST_REGEX)
60
- template <typename> class initiate_async_read_until_expr_v2;
61
- #endif // defined(BOOST_ASIO_HAS_BOOST_REGEX)
62
- template <typename> class initiate_async_read_until_match_v2;
63
-
64
- } // namespace detail
65
-
66
- /// Type trait used to determine whether a type can be used as a match condition
67
- /// function with read_until and async_read_until.
68
- template <typename T>
69
- struct is_match_condition
70
- {
71
- #if defined(GENERATING_DOCUMENTATION)
72
- /// The value member is true if the type may be used as a match condition.
73
- static const bool value;
74
- #else
75
- enum
76
- {
77
- value = boost::asio::is_function<remove_pointer_t<T>>::value
78
- || detail::has_result_type<T>::value
79
- };
80
- #endif
81
- };
82
-
83
- /**
84
- * @defgroup read_until boost::asio::read_until
85
- *
86
- * @brief The @c read_until function is a composed operation that reads data
87
- * into a dynamic buffer sequence, or into a streambuf, until it contains a
88
- * delimiter, matches a regular expression, or a function object indicates a
89
- * match.
90
- */
91
- /*@{*/
92
-
93
- #if !defined(BOOST_ASIO_NO_DYNAMIC_BUFFER_V1)
94
-
95
- /// Read data into a dynamic buffer sequence until it contains a specified
96
- /// delimiter.
97
- /**
98
- * This function is used to read data into the specified dynamic buffer
99
- * sequence until the dynamic buffer sequence's get area contains the specified
100
- * delimiter. The call will block until one of the following conditions is
101
- * true:
102
- *
103
- * @li The get area of the dynamic buffer sequence contains the specified
104
- * delimiter.
105
- *
106
- * @li An error occurred.
107
- *
108
- * This operation is implemented in terms of zero or more calls to the stream's
109
- * read_some function. If the dynamic buffer sequence's get area already
110
- * contains the delimiter, the function returns immediately.
111
- *
112
- * @param s The stream from which the data is to be read. The type must support
113
- * the SyncReadStream concept.
114
- *
115
- * @param buffers The dynamic buffer sequence into which the data will be read.
116
- *
117
- * @param delim The delimiter character.
118
- *
119
- * @returns The number of bytes in the dynamic buffer sequence's get area up to
120
- * and including the delimiter.
121
- *
122
- * @throws boost::system::system_error Thrown on failure.
123
- *
124
- * @note After a successful read_until operation, the dynamic buffer sequence
125
- * may contain additional data beyond the delimiter. An application will
126
- * typically leave that data in the dynamic buffer sequence for a subsequent
127
- * read_until operation to examine.
128
- *
129
- * @par Example
130
- * To read data into a @c std::string until a newline is encountered:
131
- * @code std::string data;
132
- * std::size_t n = boost::asio::read_until(s,
133
- * boost::asio::dynamic_buffer(data), '\n');
134
- * std::string line = data.substr(0, n);
135
- * data.erase(0, n); @endcode
136
- * After the @c read_until operation completes successfully, the string @c data
137
- * contains the delimiter:
138
- * @code { 'a', 'b', ..., 'c', '\n', 'd', 'e', ... } @endcode
139
- * The call to @c substr then extracts the data up to and including the
140
- * delimiter, so that the string @c line contains:
141
- * @code { 'a', 'b', ..., 'c', '\n' } @endcode
142
- * After the call to @c erase, the remaining data is left in the buffer @c b as
143
- * follows:
144
- * @code { 'd', 'e', ... } @endcode
145
- * This data may be the start of a new line, to be extracted by a subsequent
146
- * @c read_until operation.
147
- */
148
- template <typename SyncReadStream, typename DynamicBuffer_v1>
149
- std::size_t read_until(SyncReadStream& s,
150
- DynamicBuffer_v1&& buffers, char delim,
151
- constraint_t<
152
- is_dynamic_buffer_v1<decay_t<DynamicBuffer_v1>>::value
153
- > = 0,
154
- constraint_t<
155
- !is_dynamic_buffer_v2<decay_t<DynamicBuffer_v1>>::value
156
- > = 0);
157
-
158
- /// Read data into a dynamic buffer sequence until it contains a specified
159
- /// delimiter.
160
- /**
161
- * This function is used to read data into the specified dynamic buffer
162
- * sequence until the dynamic buffer sequence's get area contains the specified
163
- * delimiter. The call will block until one of the following conditions is
164
- * true:
165
- *
166
- * @li The get area of the dynamic buffer sequence contains the specified
167
- * delimiter.
168
- *
169
- * @li An error occurred.
170
- *
171
- * This operation is implemented in terms of zero or more calls to the stream's
172
- * read_some function. If the dynamic buffer sequence's get area already
173
- * contains the delimiter, the function returns immediately.
174
- *
175
- * @param s The stream from which the data is to be read. The type must support
176
- * the SyncReadStream concept.
177
- *
178
- * @param buffers The dynamic buffer sequence into which the data will be read.
179
- *
180
- * @param delim The delimiter character.
181
- *
182
- * @param ec Set to indicate what error occurred, if any.
183
- *
184
- * @returns The number of bytes in the dynamic buffer sequence's get area up to
185
- * and including the delimiter. Returns 0 if an error occurred.
186
- *
187
- * @note After a successful read_until operation, the dynamic buffer sequence
188
- * may contain additional data beyond the delimiter. An application will
189
- * typically leave that data in the dynamic buffer sequence for a subsequent
190
- * read_until operation to examine.
191
- */
192
- template <typename SyncReadStream, typename DynamicBuffer_v1>
193
- std::size_t read_until(SyncReadStream& s,
194
- DynamicBuffer_v1&& buffers,
195
- char delim, boost::system::error_code& ec,
196
- constraint_t<
197
- is_dynamic_buffer_v1<decay_t<DynamicBuffer_v1>>::value
198
- > = 0,
199
- constraint_t<
200
- !is_dynamic_buffer_v2<decay_t<DynamicBuffer_v1>>::value
201
- > = 0);
202
-
203
- /// Read data into a dynamic buffer sequence until it contains a specified
204
- /// delimiter.
205
- /**
206
- * This function is used to read data into the specified dynamic buffer
207
- * sequence until the dynamic buffer sequence's get area contains the specified
208
- * delimiter. The call will block until one of the following conditions is
209
- * true:
210
- *
211
- * @li The get area of the dynamic buffer sequence contains the specified
212
- * delimiter.
213
- *
214
- * @li An error occurred.
215
- *
216
- * This operation is implemented in terms of zero or more calls to the stream's
217
- * read_some function. If the dynamic buffer sequence's get area already
218
- * contains the delimiter, the function returns immediately.
219
- *
220
- * @param s The stream from which the data is to be read. The type must support
221
- * the SyncReadStream concept.
222
- *
223
- * @param buffers The dynamic buffer sequence into which the data will be read.
224
- *
225
- * @param delim The delimiter string.
226
- *
227
- * @returns The number of bytes in the dynamic buffer sequence's get area up to
228
- * and including the delimiter.
229
- *
230
- * @note After a successful read_until operation, the dynamic buffer sequence
231
- * may contain additional data beyond the delimiter. An application will
232
- * typically leave that data in the dynamic buffer sequence for a subsequent
233
- * read_until operation to examine.
234
- *
235
- * @par Example
236
- * To read data into a @c std::string until a CR-LF sequence is encountered:
237
- * @code std::string data;
238
- * std::size_t n = boost::asio::read_until(s,
239
- * boost::asio::dynamic_buffer(data), "\r\n");
240
- * std::string line = data.substr(0, n);
241
- * data.erase(0, n); @endcode
242
- * After the @c read_until operation completes successfully, the string @c data
243
- * contains the delimiter:
244
- * @code { 'a', 'b', ..., 'c', '\r', '\n', 'd', 'e', ... } @endcode
245
- * The call to @c substr then extracts the data up to and including the
246
- * delimiter, so that the string @c line contains:
247
- * @code { 'a', 'b', ..., 'c', '\r', '\n' } @endcode
248
- * After the call to @c erase, the remaining data is left in the buffer @c b as
249
- * follows:
250
- * @code { 'd', 'e', ... } @endcode
251
- * This data may be the start of a new line, to be extracted by a subsequent
252
- * @c read_until operation.
253
- */
254
- template <typename SyncReadStream, typename DynamicBuffer_v1>
255
- std::size_t read_until(SyncReadStream& s,
256
- DynamicBuffer_v1&& buffers,
257
- BOOST_ASIO_STRING_VIEW_PARAM delim,
258
- constraint_t<
259
- is_dynamic_buffer_v1<decay_t<DynamicBuffer_v1>>::value
260
- > = 0,
261
- constraint_t<
262
- !is_dynamic_buffer_v2<decay_t<DynamicBuffer_v1>>::value
263
- > = 0);
264
-
265
- /// Read data into a dynamic buffer sequence until it contains a specified
266
- /// delimiter.
267
- /**
268
- * This function is used to read data into the specified dynamic buffer
269
- * sequence until the dynamic buffer sequence's get area contains the specified
270
- * delimiter. The call will block until one of the following conditions is
271
- * true:
272
- *
273
- * @li The get area of the dynamic buffer sequence contains the specified
274
- * delimiter.
275
- *
276
- * @li An error occurred.
277
- *
278
- * This operation is implemented in terms of zero or more calls to the stream's
279
- * read_some function. If the dynamic buffer sequence's get area already
280
- * contains the delimiter, the function returns immediately.
281
- *
282
- * @param s The stream from which the data is to be read. The type must support
283
- * the SyncReadStream concept.
284
- *
285
- * @param buffers The dynamic buffer sequence into which the data will be read.
286
- *
287
- * @param delim The delimiter string.
288
- *
289
- * @param ec Set to indicate what error occurred, if any.
290
- *
291
- * @returns The number of bytes in the dynamic buffer sequence's get area up to
292
- * and including the delimiter. Returns 0 if an error occurred.
293
- *
294
- * @note After a successful read_until operation, the dynamic buffer sequence
295
- * may contain additional data beyond the delimiter. An application will
296
- * typically leave that data in the dynamic buffer sequence for a subsequent
297
- * read_until operation to examine.
298
- */
299
- template <typename SyncReadStream, typename DynamicBuffer_v1>
300
- std::size_t read_until(SyncReadStream& s,
301
- DynamicBuffer_v1&& buffers,
302
- BOOST_ASIO_STRING_VIEW_PARAM delim,
303
- boost::system::error_code& ec,
304
- constraint_t<
305
- is_dynamic_buffer_v1<decay_t<DynamicBuffer_v1>>::value
306
- > = 0,
307
- constraint_t<
308
- !is_dynamic_buffer_v2<decay_t<DynamicBuffer_v1>>::value
309
- > = 0);
310
-
311
- #if !defined(BOOST_ASIO_NO_EXTENSIONS)
312
- #if defined(BOOST_ASIO_HAS_BOOST_REGEX) \
313
- || defined(GENERATING_DOCUMENTATION)
314
-
315
- /// Read data into a dynamic buffer sequence until some part of the data it
316
- /// contains matches a regular expression.
317
- /**
318
- * This function is used to read data into the specified dynamic buffer
319
- * sequence until the dynamic buffer sequence's get area contains some data
320
- * that matches a regular expression. The call will block until one of the
321
- * following conditions is true:
322
- *
323
- * @li A substring of the dynamic buffer sequence's get area matches the
324
- * regular expression.
325
- *
326
- * @li An error occurred.
327
- *
328
- * This operation is implemented in terms of zero or more calls to the stream's
329
- * read_some function. If the dynamic buffer sequence's get area already
330
- * contains data that matches the regular expression, the function returns
331
- * immediately.
332
- *
333
- * @param s The stream from which the data is to be read. The type must support
334
- * the SyncReadStream concept.
335
- *
336
- * @param buffers A dynamic buffer sequence into which the data will be read.
337
- *
338
- * @param expr The regular expression.
339
- *
340
- * @returns The number of bytes in the dynamic buffer sequence's get area up to
341
- * and including the substring that matches the regular expression.
342
- *
343
- * @throws boost::system::system_error Thrown on failure.
344
- *
345
- * @note After a successful read_until operation, the dynamic buffer sequence
346
- * may contain additional data beyond that which matched the regular
347
- * expression. An application will typically leave that data in the dynamic
348
- * buffer sequence for a subsequent read_until operation to examine.
349
- *
350
- * @par Example
351
- * To read data into a @c std::string until a CR-LF sequence is encountered:
352
- * @code std::string data;
353
- * std::size_t n = boost::asio::read_until(s,
354
- * boost::asio::dynamic_buffer(data), boost::regex("\r\n"));
355
- * std::string line = data.substr(0, n);
356
- * data.erase(0, n); @endcode
357
- * After the @c read_until operation completes successfully, the string @c data
358
- * contains the delimiter:
359
- * @code { 'a', 'b', ..., 'c', '\r', '\n', 'd', 'e', ... } @endcode
360
- * The call to @c substr then extracts the data up to and including the
361
- * delimiter, so that the string @c line contains:
362
- * @code { 'a', 'b', ..., 'c', '\r', '\n' } @endcode
363
- * After the call to @c erase, the remaining data is left in the buffer @c b as
364
- * follows:
365
- * @code { 'd', 'e', ... } @endcode
366
- * This data may be the start of a new line, to be extracted by a subsequent
367
- * @c read_until operation.
368
- */
369
- template <typename SyncReadStream, typename DynamicBuffer_v1, typename Traits>
370
- std::size_t read_until(SyncReadStream& s, DynamicBuffer_v1&& buffers,
371
- const boost::basic_regex<char, Traits>& expr,
372
- constraint_t<
373
- is_dynamic_buffer_v1<decay_t<DynamicBuffer_v1>>::value
374
- > = 0,
375
- constraint_t<
376
- !is_dynamic_buffer_v2<decay_t<DynamicBuffer_v1>>::value
377
- > = 0);
378
-
379
- /// Read data into a dynamic buffer sequence until some part of the data it
380
- /// contains matches a regular expression.
381
- /**
382
- * This function is used to read data into the specified dynamic buffer
383
- * sequence until the dynamic buffer sequence's get area contains some data
384
- * that matches a regular expression. The call will block until one of the
385
- * following conditions is true:
386
- *
387
- * @li A substring of the dynamic buffer sequence's get area matches the
388
- * regular expression.
389
- *
390
- * @li An error occurred.
391
- *
392
- * This operation is implemented in terms of zero or more calls to the stream's
393
- * read_some function. If the dynamic buffer sequence's get area already
394
- * contains data that matches the regular expression, the function returns
395
- * immediately.
396
- *
397
- * @param s The stream from which the data is to be read. The type must support
398
- * the SyncReadStream concept.
399
- *
400
- * @param buffers A dynamic buffer sequence into which the data will be read.
401
- *
402
- * @param expr The regular expression.
403
- *
404
- * @param ec Set to indicate what error occurred, if any.
405
- *
406
- * @returns The number of bytes in the dynamic buffer sequence's get area up to
407
- * and including the substring that matches the regular expression. Returns 0
408
- * if an error occurred.
409
- *
410
- * @note After a successful read_until operation, the dynamic buffer sequence
411
- * may contain additional data beyond that which matched the regular
412
- * expression. An application will typically leave that data in the dynamic
413
- * buffer sequence for a subsequent read_until operation to examine.
414
- */
415
- template <typename SyncReadStream, typename DynamicBuffer_v1, typename Traits>
416
- std::size_t read_until(SyncReadStream& s, DynamicBuffer_v1&& buffers,
417
- const boost::basic_regex<char, Traits>& expr, boost::system::error_code& ec,
418
- constraint_t<
419
- is_dynamic_buffer_v1<decay_t<DynamicBuffer_v1>>::value
420
- > = 0,
421
- constraint_t<
422
- !is_dynamic_buffer_v2<decay_t<DynamicBuffer_v1>>::value
423
- > = 0);
424
-
425
- #endif // defined(BOOST_ASIO_HAS_BOOST_REGEX)
426
- // || defined(GENERATING_DOCUMENTATION)
427
-
428
- /// Read data into a dynamic buffer sequence until a function object indicates a
429
- /// match.
430
-
431
- /**
432
- * This function is used to read data into the specified dynamic buffer
433
- * sequence until a user-defined match condition function object, when applied
434
- * to the data contained in the dynamic buffer sequence, indicates a successful
435
- * match. The call will block until one of the following conditions is true:
436
- *
437
- * @li The match condition function object returns a std::pair where the second
438
- * element evaluates to true.
439
- *
440
- * @li An error occurred.
441
- *
442
- * This operation is implemented in terms of zero or more calls to the stream's
443
- * read_some function. If the match condition function object already indicates
444
- * a match, the function returns immediately.
445
- *
446
- * @param s The stream from which the data is to be read. The type must support
447
- * the SyncReadStream concept.
448
- *
449
- * @param buffers A dynamic buffer sequence into which the data will be read.
450
- *
451
- * @param match_condition The function object to be called to determine whether
452
- * a match exists. The signature of the function object must be:
453
- * @code pair<iterator, bool> match_condition(iterator begin, iterator end);
454
- * @endcode
455
- * where @c iterator represents the type:
456
- * @code buffers_iterator<typename DynamicBuffer_v1::const_buffers_type>
457
- * @endcode
458
- * The iterator parameters @c begin and @c end define the range of bytes to be
459
- * scanned to determine whether there is a match. The @c first member of the
460
- * return value is an iterator marking one-past-the-end of the bytes that have
461
- * been consumed by the match function. This iterator is used to calculate the
462
- * @c begin parameter for any subsequent invocation of the match condition. The
463
- * @c second member of the return value is true if a match has been found, false
464
- * otherwise.
465
- *
466
- * @returns The number of bytes in the dynamic_buffer's get area that
467
- * have been fully consumed by the match function.
468
- *
469
- * @throws boost::system::system_error Thrown on failure.
470
- *
471
- * @note After a successful read_until operation, the dynamic buffer sequence
472
- * may contain additional data beyond that which matched the function object.
473
- * An application will typically leave that data in the dynamic buffer sequence
474
- * for a subsequent read_until operation to examine.
475
-
476
- * @note The default implementation of the @c is_match_condition type trait
477
- * evaluates to true for function pointers and function objects with a
478
- * @c result_type typedef. It must be specialised for other user-defined
479
- * function objects.
480
- *
481
- * @par Examples
482
- * To read data into a dynamic buffer sequence until whitespace is encountered:
483
- * @code typedef boost::asio::buffers_iterator<
484
- * boost::asio::const_buffers_1> iterator;
485
- *
486
- * std::pair<iterator, bool>
487
- * match_whitespace(iterator begin, iterator end)
488
- * {
489
- * iterator i = begin;
490
- * while (i != end)
491
- * if (std::isspace(*i++))
492
- * return std::make_pair(i, true);
493
- * return std::make_pair(i, false);
494
- * }
495
- * ...
496
- * std::string data;
497
- * boost::asio::read_until(s, data, match_whitespace);
498
- * @endcode
499
- *
500
- * To read data into a @c std::string until a matching character is found:
501
- * @code class match_char
502
- * {
503
- * public:
504
- * explicit match_char(char c) : c_(c) {}
505
- *
506
- * template <typename Iterator>
507
- * std::pair<Iterator, bool> operator()(
508
- * Iterator begin, Iterator end) const
509
- * {
510
- * Iterator i = begin;
511
- * while (i != end)
512
- * if (c_ == *i++)
513
- * return std::make_pair(i, true);
514
- * return std::make_pair(i, false);
515
- * }
516
- *
517
- * private:
518
- * char c_;
519
- * };
520
- *
521
- * namespace asio {
522
- * template <> struct is_match_condition<match_char>
523
- * : public boost::true_type {};
524
- * } // namespace asio
525
- * ...
526
- * std::string data;
527
- * boost::asio::read_until(s, data, match_char('a'));
528
- * @endcode
529
- */
530
- template <typename SyncReadStream,
531
- typename DynamicBuffer_v1, typename MatchCondition>
532
- std::size_t read_until(SyncReadStream& s,
533
- DynamicBuffer_v1&& buffers,
534
- MatchCondition match_condition,
535
- constraint_t<
536
- is_match_condition<MatchCondition>::value
537
- > = 0,
538
- constraint_t<
539
- is_dynamic_buffer_v1<decay_t<DynamicBuffer_v1>>::value
540
- > = 0,
541
- constraint_t<
542
- !is_dynamic_buffer_v2<decay_t<DynamicBuffer_v1>>::value
543
- > = 0);
544
-
545
- /// Read data into a dynamic buffer sequence until a function object indicates a
546
- /// match.
547
- /**
548
- * This function is used to read data into the specified dynamic buffer
549
- * sequence until a user-defined match condition function object, when applied
550
- * to the data contained in the dynamic buffer sequence, indicates a successful
551
- * match. The call will block until one of the following conditions is true:
552
- *
553
- * @li The match condition function object returns a std::pair where the second
554
- * element evaluates to true.
555
- *
556
- * @li An error occurred.
557
- *
558
- * This operation is implemented in terms of zero or more calls to the stream's
559
- * read_some function. If the match condition function object already indicates
560
- * a match, the function returns immediately.
561
- *
562
- * @param s The stream from which the data is to be read. The type must support
563
- * the SyncReadStream concept.
564
- *
565
- * @param buffers A dynamic buffer sequence into which the data will be read.
566
- *
567
- * @param match_condition The function object to be called to determine whether
568
- * a match exists. The signature of the function object must be:
569
- * @code pair<iterator, bool> match_condition(iterator begin, iterator end);
570
- * @endcode
571
- * where @c iterator represents the type:
572
- * @code buffers_iterator<DynamicBuffer_v1::const_buffers_type>
573
- * @endcode
574
- * The iterator parameters @c begin and @c end define the range of bytes to be
575
- * scanned to determine whether there is a match. The @c first member of the
576
- * return value is an iterator marking one-past-the-end of the bytes that have
577
- * been consumed by the match function. This iterator is used to calculate the
578
- * @c begin parameter for any subsequent invocation of the match condition. The
579
- * @c second member of the return value is true if a match has been found, false
580
- * otherwise.
581
- *
582
- * @param ec Set to indicate what error occurred, if any.
583
- *
584
- * @returns The number of bytes in the dynamic buffer sequence's get area that
585
- * have been fully consumed by the match function. Returns 0 if an error
586
- * occurred.
587
- *
588
- * @note After a successful read_until operation, the dynamic buffer sequence
589
- * may contain additional data beyond that which matched the function object.
590
- * An application will typically leave that data in the dynamic buffer sequence
591
- * for a subsequent read_until operation to examine.
592
- *
593
- * @note The default implementation of the @c is_match_condition type trait
594
- * evaluates to true for function pointers and function objects with a
595
- * @c result_type typedef. It must be specialised for other user-defined
596
- * function objects.
597
- */
598
- template <typename SyncReadStream,
599
- typename DynamicBuffer_v1, typename MatchCondition>
600
- std::size_t read_until(SyncReadStream& s,
601
- DynamicBuffer_v1&& buffers,
602
- MatchCondition match_condition, boost::system::error_code& ec,
603
- constraint_t<
604
- is_match_condition<MatchCondition>::value
605
- > = 0,
606
- constraint_t<
607
- is_dynamic_buffer_v1<decay_t<DynamicBuffer_v1>>::value
608
- > = 0,
609
- constraint_t<
610
- !is_dynamic_buffer_v2<decay_t<DynamicBuffer_v1>>::value
611
- > = 0);
612
-
613
- #if !defined(BOOST_ASIO_NO_IOSTREAM)
614
-
615
- /// Read data into a streambuf until it contains a specified delimiter.
616
- /**
617
- * This function is used to read data into the specified streambuf until the
618
- * streambuf's get area contains the specified delimiter. The call will block
619
- * until one of the following conditions is true:
620
- *
621
- * @li The get area of the streambuf contains the specified delimiter.
622
- *
623
- * @li An error occurred.
624
- *
625
- * This operation is implemented in terms of zero or more calls to the stream's
626
- * read_some function. If the streambuf's get area already contains the
627
- * delimiter, the function returns immediately.
628
- *
629
- * @param s The stream from which the data is to be read. The type must support
630
- * the SyncReadStream concept.
631
- *
632
- * @param b A streambuf object into which the data will be read.
633
- *
634
- * @param delim The delimiter character.
635
- *
636
- * @returns The number of bytes in the streambuf's get area up to and including
637
- * the delimiter.
638
- *
639
- * @throws boost::system::system_error Thrown on failure.
640
- *
641
- * @note After a successful read_until operation, the streambuf may contain
642
- * additional data beyond the delimiter. An application will typically leave
643
- * that data in the streambuf for a subsequent read_until operation to examine.
644
- *
645
- * @par Example
646
- * To read data into a streambuf until a newline is encountered:
647
- * @code boost::asio::streambuf b;
648
- * boost::asio::read_until(s, b, '\n');
649
- * std::istream is(&b);
650
- * std::string line;
651
- * std::getline(is, line); @endcode
652
- * After the @c read_until operation completes successfully, the buffer @c b
653
- * contains the delimiter:
654
- * @code { 'a', 'b', ..., 'c', '\n', 'd', 'e', ... } @endcode
655
- * The call to @c std::getline then extracts the data up to and including the
656
- * newline (which is discarded), so that the string @c line contains:
657
- * @code { 'a', 'b', ..., 'c' } @endcode
658
- * The remaining data is left in the buffer @c b as follows:
659
- * @code { 'd', 'e', ... } @endcode
660
- * This data may be the start of a new line, to be extracted by a subsequent
661
- * @c read_until operation.
662
- */
663
- template <typename SyncReadStream, typename Allocator>
664
- std::size_t read_until(SyncReadStream& s,
665
- boost::asio::basic_streambuf<Allocator>& b, char delim);
666
-
667
- /// Read data into a streambuf until it contains a specified delimiter.
668
- /**
669
- * This function is used to read data into the specified streambuf until the
670
- * streambuf's get area contains the specified delimiter. The call will block
671
- * until one of the following conditions is true:
672
- *
673
- * @li The get area of the streambuf contains the specified delimiter.
674
- *
675
- * @li An error occurred.
676
- *
677
- * This operation is implemented in terms of zero or more calls to the stream's
678
- * read_some function. If the streambuf's get area already contains the
679
- * delimiter, the function returns immediately.
680
- *
681
- * @param s The stream from which the data is to be read. The type must support
682
- * the SyncReadStream concept.
683
- *
684
- * @param b A streambuf object into which the data will be read.
685
- *
686
- * @param delim The delimiter character.
687
- *
688
- * @param ec Set to indicate what error occurred, if any.
689
- *
690
- * @returns The number of bytes in the streambuf's get area up to and including
691
- * the delimiter. Returns 0 if an error occurred.
692
- *
693
- * @note After a successful read_until operation, the streambuf may contain
694
- * additional data beyond the delimiter. An application will typically leave
695
- * that data in the streambuf for a subsequent read_until operation to examine.
696
- */
697
- template <typename SyncReadStream, typename Allocator>
698
- std::size_t read_until(SyncReadStream& s,
699
- boost::asio::basic_streambuf<Allocator>& b, char delim,
700
- boost::system::error_code& ec);
701
-
702
- /// Read data into a streambuf until it contains a specified delimiter.
703
- /**
704
- * This function is used to read data into the specified streambuf until the
705
- * streambuf's get area contains the specified delimiter. The call will block
706
- * until one of the following conditions is true:
707
- *
708
- * @li The get area of the streambuf contains the specified delimiter.
709
- *
710
- * @li An error occurred.
711
- *
712
- * This operation is implemented in terms of zero or more calls to the stream's
713
- * read_some function. If the streambuf's get area already contains the
714
- * delimiter, the function returns immediately.
715
- *
716
- * @param s The stream from which the data is to be read. The type must support
717
- * the SyncReadStream concept.
718
- *
719
- * @param b A streambuf object into which the data will be read.
720
- *
721
- * @param delim The delimiter string.
722
- *
723
- * @returns The number of bytes in the streambuf's get area up to and including
724
- * the delimiter.
725
- *
726
- * @throws boost::system::system_error Thrown on failure.
727
- *
728
- * @note After a successful read_until operation, the streambuf may contain
729
- * additional data beyond the delimiter. An application will typically leave
730
- * that data in the streambuf for a subsequent read_until operation to examine.
731
- *
732
- * @par Example
733
- * To read data into a streambuf until a newline is encountered:
734
- * @code boost::asio::streambuf b;
735
- * boost::asio::read_until(s, b, "\r\n");
736
- * std::istream is(&b);
737
- * std::string line;
738
- * std::getline(is, line); @endcode
739
- * After the @c read_until operation completes successfully, the buffer @c b
740
- * contains the delimiter:
741
- * @code { 'a', 'b', ..., 'c', '\r', '\n', 'd', 'e', ... } @endcode
742
- * The call to @c std::getline then extracts the data up to and including the
743
- * newline (which is discarded), so that the string @c line contains:
744
- * @code { 'a', 'b', ..., 'c', '\r' } @endcode
745
- * The remaining data is left in the buffer @c b as follows:
746
- * @code { 'd', 'e', ... } @endcode
747
- * This data may be the start of a new line, to be extracted by a subsequent
748
- * @c read_until operation.
749
- */
750
- template <typename SyncReadStream, typename Allocator>
751
- std::size_t read_until(SyncReadStream& s,
752
- boost::asio::basic_streambuf<Allocator>& b,
753
- BOOST_ASIO_STRING_VIEW_PARAM delim);
754
-
755
- /// Read data into a streambuf until it contains a specified delimiter.
756
- /**
757
- * This function is used to read data into the specified streambuf until the
758
- * streambuf's get area contains the specified delimiter. The call will block
759
- * until one of the following conditions is true:
760
- *
761
- * @li The get area of the streambuf contains the specified delimiter.
762
- *
763
- * @li An error occurred.
764
- *
765
- * This operation is implemented in terms of zero or more calls to the stream's
766
- * read_some function. If the streambuf's get area already contains the
767
- * delimiter, the function returns immediately.
768
- *
769
- * @param s The stream from which the data is to be read. The type must support
770
- * the SyncReadStream concept.
771
- *
772
- * @param b A streambuf object into which the data will be read.
773
- *
774
- * @param delim The delimiter string.
775
- *
776
- * @param ec Set to indicate what error occurred, if any.
777
- *
778
- * @returns The number of bytes in the streambuf's get area up to and including
779
- * the delimiter. Returns 0 if an error occurred.
780
- *
781
- * @note After a successful read_until operation, the streambuf may contain
782
- * additional data beyond the delimiter. An application will typically leave
783
- * that data in the streambuf for a subsequent read_until operation to examine.
784
- */
785
- template <typename SyncReadStream, typename Allocator>
786
- std::size_t read_until(SyncReadStream& s,
787
- boost::asio::basic_streambuf<Allocator>& b,
788
- BOOST_ASIO_STRING_VIEW_PARAM delim, boost::system::error_code& ec);
789
-
790
- #if defined(BOOST_ASIO_HAS_BOOST_REGEX) \
791
- || defined(GENERATING_DOCUMENTATION)
792
-
793
- /// Read data into a streambuf until some part of the data it contains matches
794
- /// a regular expression.
795
- /**
796
- * This function is used to read data into the specified streambuf until the
797
- * streambuf's get area contains some data that matches a regular expression.
798
- * The call will block until one of the following conditions is true:
799
- *
800
- * @li A substring of the streambuf's get area matches the regular expression.
801
- *
802
- * @li An error occurred.
803
- *
804
- * This operation is implemented in terms of zero or more calls to the stream's
805
- * read_some function. If the streambuf's get area already contains data that
806
- * matches the regular expression, the function returns immediately.
807
- *
808
- * @param s The stream from which the data is to be read. The type must support
809
- * the SyncReadStream concept.
810
- *
811
- * @param b A streambuf object into which the data will be read.
812
- *
813
- * @param expr The regular expression.
814
- *
815
- * @returns The number of bytes in the streambuf's get area up to and including
816
- * the substring that matches the regular expression.
817
- *
818
- * @throws boost::system::system_error Thrown on failure.
819
- *
820
- * @note After a successful read_until operation, the streambuf may contain
821
- * additional data beyond that which matched the regular expression. An
822
- * application will typically leave that data in the streambuf for a subsequent
823
- * read_until operation to examine.
824
- *
825
- * @par Example
826
- * To read data into a streambuf until a CR-LF sequence is encountered:
827
- * @code boost::asio::streambuf b;
828
- * boost::asio::read_until(s, b, boost::regex("\r\n"));
829
- * std::istream is(&b);
830
- * std::string line;
831
- * std::getline(is, line); @endcode
832
- * After the @c read_until operation completes successfully, the buffer @c b
833
- * contains the data which matched the regular expression:
834
- * @code { 'a', 'b', ..., 'c', '\r', '\n', 'd', 'e', ... } @endcode
835
- * The call to @c std::getline then extracts the data up to and including the
836
- * newline (which is discarded), so that the string @c line contains:
837
- * @code { 'a', 'b', ..., 'c', '\r' } @endcode
838
- * The remaining data is left in the buffer @c b as follows:
839
- * @code { 'd', 'e', ... } @endcode
840
- * This data may be the start of a new line, to be extracted by a subsequent
841
- * @c read_until operation.
842
- */
843
- template <typename SyncReadStream, typename Allocator, typename Traits>
844
- std::size_t read_until(SyncReadStream& s,
845
- boost::asio::basic_streambuf<Allocator>& b,
846
- const boost::basic_regex<char, Traits>& expr);
847
-
848
- /// Read data into a streambuf until some part of the data it contains matches
849
- /// a regular expression.
850
- /**
851
- * This function is used to read data into the specified streambuf until the
852
- * streambuf's get area contains some data that matches a regular expression.
853
- * The call will block until one of the following conditions is true:
854
- *
855
- * @li A substring of the streambuf's get area matches the regular expression.
856
- *
857
- * @li An error occurred.
858
- *
859
- * This operation is implemented in terms of zero or more calls to the stream's
860
- * read_some function. If the streambuf's get area already contains data that
861
- * matches the regular expression, the function returns immediately.
862
- *
863
- * @param s The stream from which the data is to be read. The type must support
864
- * the SyncReadStream concept.
865
- *
866
- * @param b A streambuf object into which the data will be read.
867
- *
868
- * @param expr The regular expression.
869
- *
870
- * @param ec Set to indicate what error occurred, if any.
871
- *
872
- * @returns The number of bytes in the streambuf's get area up to and including
873
- * the substring that matches the regular expression. Returns 0 if an error
874
- * occurred.
875
- *
876
- * @note After a successful read_until operation, the streambuf may contain
877
- * additional data beyond that which matched the regular expression. An
878
- * application will typically leave that data in the streambuf for a subsequent
879
- * read_until operation to examine.
880
- */
881
- template <typename SyncReadStream, typename Allocator, typename Traits>
882
- std::size_t read_until(SyncReadStream& s,
883
- boost::asio::basic_streambuf<Allocator>& b,
884
- const boost::basic_regex<char, Traits>& expr,
885
- boost::system::error_code& ec);
886
-
887
- #endif // defined(BOOST_ASIO_HAS_BOOST_REGEX)
888
- // || defined(GENERATING_DOCUMENTATION)
889
-
890
- /// Read data into a streambuf until a function object indicates a match.
891
- /**
892
- * This function is used to read data into the specified streambuf until a
893
- * user-defined match condition function object, when applied to the data
894
- * contained in the streambuf, indicates a successful match. The call will
895
- * block until one of the following conditions is true:
896
- *
897
- * @li The match condition function object returns a std::pair where the second
898
- * element evaluates to true.
899
- *
900
- * @li An error occurred.
901
- *
902
- * This operation is implemented in terms of zero or more calls to the stream's
903
- * read_some function. If the match condition function object already indicates
904
- * a match, the function returns immediately.
905
- *
906
- * @param s The stream from which the data is to be read. The type must support
907
- * the SyncReadStream concept.
908
- *
909
- * @param b A streambuf object into which the data will be read.
910
- *
911
- * @param match_condition The function object to be called to determine whether
912
- * a match exists. The signature of the function object must be:
913
- * @code pair<iterator, bool> match_condition(iterator begin, iterator end);
914
- * @endcode
915
- * where @c iterator represents the type:
916
- * @code buffers_iterator<basic_streambuf<Allocator>::const_buffers_type>
917
- * @endcode
918
- * The iterator parameters @c begin and @c end define the range of bytes to be
919
- * scanned to determine whether there is a match. The @c first member of the
920
- * return value is an iterator marking one-past-the-end of the bytes that have
921
- * been consumed by the match function. This iterator is used to calculate the
922
- * @c begin parameter for any subsequent invocation of the match condition. The
923
- * @c second member of the return value is true if a match has been found, false
924
- * otherwise.
925
- *
926
- * @returns The number of bytes in the streambuf's get area that have been fully
927
- * consumed by the match function.
928
- *
929
- * @throws boost::system::system_error Thrown on failure.
930
- *
931
- * @note After a successful read_until operation, the streambuf may contain
932
- * additional data beyond that which matched the function object. An application
933
- * will typically leave that data in the streambuf for a subsequent read_until
934
- * operation to examine.
935
- *
936
- * @note The default implementation of the @c is_match_condition type trait
937
- * evaluates to true for function pointers and function objects with a
938
- * @c result_type typedef. It must be specialised for other user-defined
939
- * function objects.
940
- *
941
- * @par Examples
942
- * To read data into a streambuf until whitespace is encountered:
943
- * @code typedef boost::asio::buffers_iterator<
944
- * boost::asio::streambuf::const_buffers_type> iterator;
945
- *
946
- * std::pair<iterator, bool>
947
- * match_whitespace(iterator begin, iterator end)
948
- * {
949
- * iterator i = begin;
950
- * while (i != end)
951
- * if (std::isspace(*i++))
952
- * return std::make_pair(i, true);
953
- * return std::make_pair(i, false);
954
- * }
955
- * ...
956
- * boost::asio::streambuf b;
957
- * boost::asio::read_until(s, b, match_whitespace);
958
- * @endcode
959
- *
960
- * To read data into a streambuf until a matching character is found:
961
- * @code class match_char
962
- * {
963
- * public:
964
- * explicit match_char(char c) : c_(c) {}
965
- *
966
- * template <typename Iterator>
967
- * std::pair<Iterator, bool> operator()(
968
- * Iterator begin, Iterator end) const
969
- * {
970
- * Iterator i = begin;
971
- * while (i != end)
972
- * if (c_ == *i++)
973
- * return std::make_pair(i, true);
974
- * return std::make_pair(i, false);
975
- * }
976
- *
977
- * private:
978
- * char c_;
979
- * };
980
- *
981
- * namespace asio {
982
- * template <> struct is_match_condition<match_char>
983
- * : public boost::true_type {};
984
- * } // namespace asio
985
- * ...
986
- * boost::asio::streambuf b;
987
- * boost::asio::read_until(s, b, match_char('a'));
988
- * @endcode
989
- */
990
- template <typename SyncReadStream, typename Allocator, typename MatchCondition>
991
- std::size_t read_until(SyncReadStream& s,
992
- boost::asio::basic_streambuf<Allocator>& b, MatchCondition match_condition,
993
- constraint_t<is_match_condition<MatchCondition>::value> = 0);
994
-
995
- /// Read data into a streambuf until a function object indicates a match.
996
- /**
997
- * This function is used to read data into the specified streambuf until a
998
- * user-defined match condition function object, when applied to the data
999
- * contained in the streambuf, indicates a successful match. The call will
1000
- * block until one of the following conditions is true:
1001
- *
1002
- * @li The match condition function object returns a std::pair where the second
1003
- * element evaluates to true.
1004
- *
1005
- * @li An error occurred.
1006
- *
1007
- * This operation is implemented in terms of zero or more calls to the stream's
1008
- * read_some function. If the match condition function object already indicates
1009
- * a match, the function returns immediately.
1010
- *
1011
- * @param s The stream from which the data is to be read. The type must support
1012
- * the SyncReadStream concept.
1013
- *
1014
- * @param b A streambuf object into which the data will be read.
1015
- *
1016
- * @param match_condition The function object to be called to determine whether
1017
- * a match exists. The signature of the function object must be:
1018
- * @code pair<iterator, bool> match_condition(iterator begin, iterator end);
1019
- * @endcode
1020
- * where @c iterator represents the type:
1021
- * @code buffers_iterator<basic_streambuf<Allocator>::const_buffers_type>
1022
- * @endcode
1023
- * The iterator parameters @c begin and @c end define the range of bytes to be
1024
- * scanned to determine whether there is a match. The @c first member of the
1025
- * return value is an iterator marking one-past-the-end of the bytes that have
1026
- * been consumed by the match function. This iterator is used to calculate the
1027
- * @c begin parameter for any subsequent invocation of the match condition. The
1028
- * @c second member of the return value is true if a match has been found, false
1029
- * otherwise.
1030
- *
1031
- * @param ec Set to indicate what error occurred, if any.
1032
- *
1033
- * @returns The number of bytes in the streambuf's get area that have been fully
1034
- * consumed by the match function. Returns 0 if an error occurred.
1035
- *
1036
- * @note After a successful read_until operation, the streambuf may contain
1037
- * additional data beyond that which matched the function object. An application
1038
- * will typically leave that data in the streambuf for a subsequent read_until
1039
- * operation to examine.
1040
- *
1041
- * @note The default implementation of the @c is_match_condition type trait
1042
- * evaluates to true for function pointers and function objects with a
1043
- * @c result_type typedef. It must be specialised for other user-defined
1044
- * function objects.
1045
- */
1046
- template <typename SyncReadStream, typename Allocator, typename MatchCondition>
1047
- std::size_t read_until(SyncReadStream& s,
1048
- boost::asio::basic_streambuf<Allocator>& b,
1049
- MatchCondition match_condition, boost::system::error_code& ec,
1050
- constraint_t<is_match_condition<MatchCondition>::value> = 0);
1051
-
1052
- #endif // !defined(BOOST_ASIO_NO_IOSTREAM)
1053
- #endif // !defined(BOOST_ASIO_NO_EXTENSIONS)
1054
- #endif // !defined(BOOST_ASIO_NO_DYNAMIC_BUFFER_V1)
1055
-
1056
- /// Read data into a dynamic buffer sequence until it contains a specified
1057
- /// delimiter.
1058
- /**
1059
- * This function is used to read data into the specified dynamic buffer
1060
- * sequence until the dynamic buffer sequence's get area contains the specified
1061
- * delimiter. The call will block until one of the following conditions is
1062
- * true:
1063
- *
1064
- * @li The get area of the dynamic buffer sequence contains the specified
1065
- * delimiter.
1066
- *
1067
- * @li An error occurred.
1068
- *
1069
- * This operation is implemented in terms of zero or more calls to the stream's
1070
- * read_some function. If the dynamic buffer sequence's get area already
1071
- * contains the delimiter, the function returns immediately.
1072
- *
1073
- * @param s The stream from which the data is to be read. The type must support
1074
- * the SyncReadStream concept.
1075
- *
1076
- * @param buffers The dynamic buffer sequence into which the data will be read.
1077
- *
1078
- * @param delim The delimiter character.
1079
- *
1080
- * @returns The number of bytes in the dynamic buffer sequence's get area up to
1081
- * and including the delimiter.
1082
- *
1083
- * @throws boost::system::system_error Thrown on failure.
1084
- *
1085
- * @note After a successful read_until operation, the dynamic buffer sequence
1086
- * may contain additional data beyond the delimiter. An application will
1087
- * typically leave that data in the dynamic buffer sequence for a subsequent
1088
- * read_until operation to examine.
1089
- *
1090
- * @par Example
1091
- * To read data into a @c std::string until a newline is encountered:
1092
- * @code std::string data;
1093
- * std::size_t n = boost::asio::read_until(s,
1094
- * boost::asio::dynamic_buffer(data), '\n');
1095
- * std::string line = data.substr(0, n);
1096
- * data.erase(0, n); @endcode
1097
- * After the @c read_until operation completes successfully, the string @c data
1098
- * contains the delimiter:
1099
- * @code { 'a', 'b', ..., 'c', '\n', 'd', 'e', ... } @endcode
1100
- * The call to @c substr then extracts the data up to and including the
1101
- * delimiter, so that the string @c line contains:
1102
- * @code { 'a', 'b', ..., 'c', '\n' } @endcode
1103
- * After the call to @c erase, the remaining data is left in the buffer @c b as
1104
- * follows:
1105
- * @code { 'd', 'e', ... } @endcode
1106
- * This data may be the start of a new line, to be extracted by a subsequent
1107
- * @c read_until operation.
1108
- */
1109
- template <typename SyncReadStream, typename DynamicBuffer_v2>
1110
- std::size_t read_until(SyncReadStream& s, DynamicBuffer_v2 buffers, char delim,
1111
- constraint_t<
1112
- is_dynamic_buffer_v2<DynamicBuffer_v2>::value
1113
- > = 0);
1114
-
1115
- /// Read data into a dynamic buffer sequence until it contains a specified
1116
- /// delimiter.
1117
- /**
1118
- * This function is used to read data into the specified dynamic buffer
1119
- * sequence until the dynamic buffer sequence's get area contains the specified
1120
- * delimiter. The call will block until one of the following conditions is
1121
- * true:
1122
- *
1123
- * @li The get area of the dynamic buffer sequence contains the specified
1124
- * delimiter.
1125
- *
1126
- * @li An error occurred.
1127
- *
1128
- * This operation is implemented in terms of zero or more calls to the stream's
1129
- * read_some function. If the dynamic buffer sequence's get area already
1130
- * contains the delimiter, the function returns immediately.
1131
- *
1132
- * @param s The stream from which the data is to be read. The type must support
1133
- * the SyncReadStream concept.
1134
- *
1135
- * @param buffers The dynamic buffer sequence into which the data will be read.
1136
- *
1137
- * @param delim The delimiter character.
1138
- *
1139
- * @param ec Set to indicate what error occurred, if any.
1140
- *
1141
- * @returns The number of bytes in the dynamic buffer sequence's get area up to
1142
- * and including the delimiter. Returns 0 if an error occurred.
1143
- *
1144
- * @note After a successful read_until operation, the dynamic buffer sequence
1145
- * may contain additional data beyond the delimiter. An application will
1146
- * typically leave that data in the dynamic buffer sequence for a subsequent
1147
- * read_until operation to examine.
1148
- */
1149
- template <typename SyncReadStream, typename DynamicBuffer_v2>
1150
- std::size_t read_until(SyncReadStream& s, DynamicBuffer_v2 buffers,
1151
- char delim, boost::system::error_code& ec,
1152
- constraint_t<
1153
- is_dynamic_buffer_v2<DynamicBuffer_v2>::value
1154
- > = 0);
1155
-
1156
- /// Read data into a dynamic buffer sequence until it contains a specified
1157
- /// delimiter.
1158
- /**
1159
- * This function is used to read data into the specified dynamic buffer
1160
- * sequence until the dynamic buffer sequence's get area contains the specified
1161
- * delimiter. The call will block until one of the following conditions is
1162
- * true:
1163
- *
1164
- * @li The get area of the dynamic buffer sequence contains the specified
1165
- * delimiter.
1166
- *
1167
- * @li An error occurred.
1168
- *
1169
- * This operation is implemented in terms of zero or more calls to the stream's
1170
- * read_some function. If the dynamic buffer sequence's get area already
1171
- * contains the delimiter, the function returns immediately.
1172
- *
1173
- * @param s The stream from which the data is to be read. The type must support
1174
- * the SyncReadStream concept.
1175
- *
1176
- * @param buffers The dynamic buffer sequence into which the data will be read.
1177
- *
1178
- * @param delim The delimiter string.
1179
- *
1180
- * @returns The number of bytes in the dynamic buffer sequence's get area up to
1181
- * and including the delimiter.
1182
- *
1183
- * @note After a successful read_until operation, the dynamic buffer sequence
1184
- * may contain additional data beyond the delimiter. An application will
1185
- * typically leave that data in the dynamic buffer sequence for a subsequent
1186
- * read_until operation to examine.
1187
- *
1188
- * @par Example
1189
- * To read data into a @c std::string until a CR-LF sequence is encountered:
1190
- * @code std::string data;
1191
- * std::size_t n = boost::asio::read_until(s,
1192
- * boost::asio::dynamic_buffer(data), "\r\n");
1193
- * std::string line = data.substr(0, n);
1194
- * data.erase(0, n); @endcode
1195
- * After the @c read_until operation completes successfully, the string @c data
1196
- * contains the delimiter:
1197
- * @code { 'a', 'b', ..., 'c', '\r', '\n', 'd', 'e', ... } @endcode
1198
- * The call to @c substr then extracts the data up to and including the
1199
- * delimiter, so that the string @c line contains:
1200
- * @code { 'a', 'b', ..., 'c', '\r', '\n' } @endcode
1201
- * After the call to @c erase, the remaining data is left in the buffer @c b as
1202
- * follows:
1203
- * @code { 'd', 'e', ... } @endcode
1204
- * This data may be the start of a new line, to be extracted by a subsequent
1205
- * @c read_until operation.
1206
- */
1207
- template <typename SyncReadStream, typename DynamicBuffer_v2>
1208
- std::size_t read_until(SyncReadStream& s, DynamicBuffer_v2 buffers,
1209
- BOOST_ASIO_STRING_VIEW_PARAM delim,
1210
- constraint_t<
1211
- is_dynamic_buffer_v2<DynamicBuffer_v2>::value
1212
- > = 0);
1213
-
1214
- /// Read data into a dynamic buffer sequence until it contains a specified
1215
- /// delimiter.
1216
- /**
1217
- * This function is used to read data into the specified dynamic buffer
1218
- * sequence until the dynamic buffer sequence's get area contains the specified
1219
- * delimiter. The call will block until one of the following conditions is
1220
- * true:
1221
- *
1222
- * @li The get area of the dynamic buffer sequence contains the specified
1223
- * delimiter.
1224
- *
1225
- * @li An error occurred.
1226
- *
1227
- * This operation is implemented in terms of zero or more calls to the stream's
1228
- * read_some function. If the dynamic buffer sequence's get area already
1229
- * contains the delimiter, the function returns immediately.
1230
- *
1231
- * @param s The stream from which the data is to be read. The type must support
1232
- * the SyncReadStream concept.
1233
- *
1234
- * @param buffers The dynamic buffer sequence into which the data will be read.
1235
- *
1236
- * @param delim The delimiter string.
1237
- *
1238
- * @param ec Set to indicate what error occurred, if any.
1239
- *
1240
- * @returns The number of bytes in the dynamic buffer sequence's get area up to
1241
- * and including the delimiter. Returns 0 if an error occurred.
1242
- *
1243
- * @note After a successful read_until operation, the dynamic buffer sequence
1244
- * may contain additional data beyond the delimiter. An application will
1245
- * typically leave that data in the dynamic buffer sequence for a subsequent
1246
- * read_until operation to examine.
1247
- */
1248
- template <typename SyncReadStream, typename DynamicBuffer_v2>
1249
- std::size_t read_until(SyncReadStream& s, DynamicBuffer_v2 buffers,
1250
- BOOST_ASIO_STRING_VIEW_PARAM delim, boost::system::error_code& ec,
1251
- constraint_t<
1252
- is_dynamic_buffer_v2<DynamicBuffer_v2>::value
1253
- > = 0);
1254
-
1255
- #if !defined(BOOST_ASIO_NO_EXTENSIONS)
1256
- #if defined(BOOST_ASIO_HAS_BOOST_REGEX) \
1257
- || defined(GENERATING_DOCUMENTATION)
1258
-
1259
- /// Read data into a dynamic buffer sequence until some part of the data it
1260
- /// contains matches a regular expression.
1261
- /**
1262
- * This function is used to read data into the specified dynamic buffer
1263
- * sequence until the dynamic buffer sequence's get area contains some data
1264
- * that matches a regular expression. The call will block until one of the
1265
- * following conditions is true:
1266
- *
1267
- * @li A substring of the dynamic buffer sequence's get area matches the
1268
- * regular expression.
1269
- *
1270
- * @li An error occurred.
1271
- *
1272
- * This operation is implemented in terms of zero or more calls to the stream's
1273
- * read_some function. If the dynamic buffer sequence's get area already
1274
- * contains data that matches the regular expression, the function returns
1275
- * immediately.
1276
- *
1277
- * @param s The stream from which the data is to be read. The type must support
1278
- * the SyncReadStream concept.
1279
- *
1280
- * @param buffers A dynamic buffer sequence into which the data will be read.
1281
- *
1282
- * @param expr The regular expression.
1283
- *
1284
- * @returns The number of bytes in the dynamic buffer sequence's get area up to
1285
- * and including the substring that matches the regular expression.
1286
- *
1287
- * @throws boost::system::system_error Thrown on failure.
1288
- *
1289
- * @note After a successful read_until operation, the dynamic buffer sequence
1290
- * may contain additional data beyond that which matched the regular
1291
- * expression. An application will typically leave that data in the dynamic
1292
- * buffer sequence for a subsequent read_until operation to examine.
1293
- *
1294
- * @par Example
1295
- * To read data into a @c std::string until a CR-LF sequence is encountered:
1296
- * @code std::string data;
1297
- * std::size_t n = boost::asio::read_until(s,
1298
- * boost::asio::dynamic_buffer(data), boost::regex("\r\n"));
1299
- * std::string line = data.substr(0, n);
1300
- * data.erase(0, n); @endcode
1301
- * After the @c read_until operation completes successfully, the string @c data
1302
- * contains the delimiter:
1303
- * @code { 'a', 'b', ..., 'c', '\r', '\n', 'd', 'e', ... } @endcode
1304
- * The call to @c substr then extracts the data up to and including the
1305
- * delimiter, so that the string @c line contains:
1306
- * @code { 'a', 'b', ..., 'c', '\r', '\n' } @endcode
1307
- * After the call to @c erase, the remaining data is left in the buffer @c b as
1308
- * follows:
1309
- * @code { 'd', 'e', ... } @endcode
1310
- * This data may be the start of a new line, to be extracted by a subsequent
1311
- * @c read_until operation.
1312
- */
1313
- template <typename SyncReadStream, typename DynamicBuffer_v2, typename Traits>
1314
- std::size_t read_until(SyncReadStream& s, DynamicBuffer_v2 buffers,
1315
- const boost::basic_regex<char, Traits>& expr,
1316
- constraint_t<
1317
- is_dynamic_buffer_v2<DynamicBuffer_v2>::value
1318
- > = 0);
1319
-
1320
- /// Read data into a dynamic buffer sequence until some part of the data it
1321
- /// contains matches a regular expression.
1322
- /**
1323
- * This function is used to read data into the specified dynamic buffer
1324
- * sequence until the dynamic buffer sequence's get area contains some data
1325
- * that matches a regular expression. The call will block until one of the
1326
- * following conditions is true:
1327
- *
1328
- * @li A substring of the dynamic buffer sequence's get area matches the
1329
- * regular expression.
1330
- *
1331
- * @li An error occurred.
1332
- *
1333
- * This operation is implemented in terms of zero or more calls to the stream's
1334
- * read_some function. If the dynamic buffer sequence's get area already
1335
- * contains data that matches the regular expression, the function returns
1336
- * immediately.
1337
- *
1338
- * @param s The stream from which the data is to be read. The type must support
1339
- * the SyncReadStream concept.
1340
- *
1341
- * @param buffers A dynamic buffer sequence into which the data will be read.
1342
- *
1343
- * @param expr The regular expression.
1344
- *
1345
- * @param ec Set to indicate what error occurred, if any.
1346
- *
1347
- * @returns The number of bytes in the dynamic buffer sequence's get area up to
1348
- * and including the substring that matches the regular expression. Returns 0
1349
- * if an error occurred.
1350
- *
1351
- * @note After a successful read_until operation, the dynamic buffer sequence
1352
- * may contain additional data beyond that which matched the regular
1353
- * expression. An application will typically leave that data in the dynamic
1354
- * buffer sequence for a subsequent read_until operation to examine.
1355
- */
1356
- template <typename SyncReadStream, typename DynamicBuffer_v2, typename Traits>
1357
- std::size_t read_until(SyncReadStream& s, DynamicBuffer_v2 buffers,
1358
- const boost::basic_regex<char, Traits>& expr, boost::system::error_code& ec,
1359
- constraint_t<
1360
- is_dynamic_buffer_v2<DynamicBuffer_v2>::value
1361
- > = 0);
1362
-
1363
- #endif // defined(BOOST_ASIO_HAS_BOOST_REGEX)
1364
- // || defined(GENERATING_DOCUMENTATION)
1365
-
1366
- /// Read data into a dynamic buffer sequence until a function object indicates a
1367
- /// match.
1368
-
1369
- /**
1370
- * This function is used to read data into the specified dynamic buffer
1371
- * sequence until a user-defined match condition function object, when applied
1372
- * to the data contained in the dynamic buffer sequence, indicates a successful
1373
- * match. The call will block until one of the following conditions is true:
1374
- *
1375
- * @li The match condition function object returns a std::pair where the second
1376
- * element evaluates to true.
1377
- *
1378
- * @li An error occurred.
1379
- *
1380
- * This operation is implemented in terms of zero or more calls to the stream's
1381
- * read_some function. If the match condition function object already indicates
1382
- * a match, the function returns immediately.
1383
- *
1384
- * @param s The stream from which the data is to be read. The type must support
1385
- * the SyncReadStream concept.
1386
- *
1387
- * @param buffers A dynamic buffer sequence into which the data will be read.
1388
- *
1389
- * @param match_condition The function object to be called to determine whether
1390
- * a match exists. The signature of the function object must be:
1391
- * @code pair<iterator, bool> match_condition(iterator begin, iterator end);
1392
- * @endcode
1393
- * where @c iterator represents the type:
1394
- * @code buffers_iterator<typename DynamicBuffer_v2::const_buffers_type>
1395
- * @endcode
1396
- * The iterator parameters @c begin and @c end define the range of bytes to be
1397
- * scanned to determine whether there is a match. The @c first member of the
1398
- * return value is an iterator marking one-past-the-end of the bytes that have
1399
- * been consumed by the match function. This iterator is used to calculate the
1400
- * @c begin parameter for any subsequent invocation of the match condition. The
1401
- * @c second member of the return value is true if a match has been found, false
1402
- * otherwise.
1403
- *
1404
- * @returns The number of bytes in the dynamic_buffer's get area that
1405
- * have been fully consumed by the match function.
1406
- *
1407
- * @throws boost::system::system_error Thrown on failure.
1408
- *
1409
- * @note After a successful read_until operation, the dynamic buffer sequence
1410
- * may contain additional data beyond that which matched the function object.
1411
- * An application will typically leave that data in the dynamic buffer sequence
1412
- * for a subsequent read_until operation to examine.
1413
-
1414
- * @note The default implementation of the @c is_match_condition type trait
1415
- * evaluates to true for function pointers and function objects with a
1416
- * @c result_type typedef. It must be specialised for other user-defined
1417
- * function objects.
1418
- *
1419
- * @par Examples
1420
- * To read data into a dynamic buffer sequence until whitespace is encountered:
1421
- * @code typedef boost::asio::buffers_iterator<
1422
- * boost::asio::const_buffers_1> iterator;
1423
- *
1424
- * std::pair<iterator, bool>
1425
- * match_whitespace(iterator begin, iterator end)
1426
- * {
1427
- * iterator i = begin;
1428
- * while (i != end)
1429
- * if (std::isspace(*i++))
1430
- * return std::make_pair(i, true);
1431
- * return std::make_pair(i, false);
1432
- * }
1433
- * ...
1434
- * std::string data;
1435
- * boost::asio::read_until(s, data, match_whitespace);
1436
- * @endcode
1437
- *
1438
- * To read data into a @c std::string until a matching character is found:
1439
- * @code class match_char
1440
- * {
1441
- * public:
1442
- * explicit match_char(char c) : c_(c) {}
1443
- *
1444
- * template <typename Iterator>
1445
- * std::pair<Iterator, bool> operator()(
1446
- * Iterator begin, Iterator end) const
1447
- * {
1448
- * Iterator i = begin;
1449
- * while (i != end)
1450
- * if (c_ == *i++)
1451
- * return std::make_pair(i, true);
1452
- * return std::make_pair(i, false);
1453
- * }
1454
- *
1455
- * private:
1456
- * char c_;
1457
- * };
1458
- *
1459
- * namespace asio {
1460
- * template <> struct is_match_condition<match_char>
1461
- * : public boost::true_type {};
1462
- * } // namespace asio
1463
- * ...
1464
- * std::string data;
1465
- * boost::asio::read_until(s, data, match_char('a'));
1466
- * @endcode
1467
- */
1468
- template <typename SyncReadStream,
1469
- typename DynamicBuffer_v2, typename MatchCondition>
1470
- std::size_t read_until(SyncReadStream& s, DynamicBuffer_v2 buffers,
1471
- MatchCondition match_condition,
1472
- constraint_t<
1473
- is_match_condition<MatchCondition>::value
1474
- > = 0,
1475
- constraint_t<
1476
- is_dynamic_buffer_v2<DynamicBuffer_v2>::value
1477
- > = 0);
1478
-
1479
- /// Read data into a dynamic buffer sequence until a function object indicates a
1480
- /// match.
1481
- /**
1482
- * This function is used to read data into the specified dynamic buffer
1483
- * sequence until a user-defined match condition function object, when applied
1484
- * to the data contained in the dynamic buffer sequence, indicates a successful
1485
- * match. The call will block until one of the following conditions is true:
1486
- *
1487
- * @li The match condition function object returns a std::pair where the second
1488
- * element evaluates to true.
1489
- *
1490
- * @li An error occurred.
1491
- *
1492
- * This operation is implemented in terms of zero or more calls to the stream's
1493
- * read_some function. If the match condition function object already indicates
1494
- * a match, the function returns immediately.
1495
- *
1496
- * @param s The stream from which the data is to be read. The type must support
1497
- * the SyncReadStream concept.
1498
- *
1499
- * @param buffers A dynamic buffer sequence into which the data will be read.
1500
- *
1501
- * @param match_condition The function object to be called to determine whether
1502
- * a match exists. The signature of the function object must be:
1503
- * @code pair<iterator, bool> match_condition(iterator begin, iterator end);
1504
- * @endcode
1505
- * where @c iterator represents the type:
1506
- * @code buffers_iterator<DynamicBuffer_v2::const_buffers_type>
1507
- * @endcode
1508
- * The iterator parameters @c begin and @c end define the range of bytes to be
1509
- * scanned to determine whether there is a match. The @c first member of the
1510
- * return value is an iterator marking one-past-the-end of the bytes that have
1511
- * been consumed by the match function. This iterator is used to calculate the
1512
- * @c begin parameter for any subsequent invocation of the match condition. The
1513
- * @c second member of the return value is true if a match has been found, false
1514
- * otherwise.
1515
- *
1516
- * @param ec Set to indicate what error occurred, if any.
1517
- *
1518
- * @returns The number of bytes in the dynamic buffer sequence's get area that
1519
- * have been fully consumed by the match function. Returns 0 if an error
1520
- * occurred.
1521
- *
1522
- * @note After a successful read_until operation, the dynamic buffer sequence
1523
- * may contain additional data beyond that which matched the function object.
1524
- * An application will typically leave that data in the dynamic buffer sequence
1525
- * for a subsequent read_until operation to examine.
1526
- *
1527
- * @note The default implementation of the @c is_match_condition type trait
1528
- * evaluates to true for function pointers and function objects with a
1529
- * @c result_type typedef. It must be specialised for other user-defined
1530
- * function objects.
1531
- */
1532
- template <typename SyncReadStream,
1533
- typename DynamicBuffer_v2, typename MatchCondition>
1534
- std::size_t read_until(SyncReadStream& s, DynamicBuffer_v2 buffers,
1535
- MatchCondition match_condition, boost::system::error_code& ec,
1536
- constraint_t<
1537
- is_match_condition<MatchCondition>::value
1538
- > = 0,
1539
- constraint_t<
1540
- is_dynamic_buffer_v2<DynamicBuffer_v2>::value
1541
- > = 0);
1542
-
1543
- #endif // !defined(BOOST_ASIO_NO_EXTENSIONS)
1544
-
1545
- /*@}*/
1546
- /**
1547
- * @defgroup async_read_until boost::asio::async_read_until
1548
- *
1549
- * @brief The @c async_read_until function is a composed asynchronous operation
1550
- * that reads data into a dynamic buffer sequence, or into a streambuf, until
1551
- * it contains a delimiter, matches a regular expression, or a function object
1552
- * indicates a match.
1553
- */
1554
- /*@{*/
1555
-
1556
- #if !defined(BOOST_ASIO_NO_DYNAMIC_BUFFER_V1)
1557
-
1558
- /// Start an asynchronous operation to read data into a dynamic buffer sequence
1559
- /// until it contains a specified delimiter.
1560
- /**
1561
- * This function is used to asynchronously read data into the specified dynamic
1562
- * buffer sequence until the dynamic buffer sequence's get area contains the
1563
- * specified delimiter. It is an initiating function for an @ref
1564
- * asynchronous_operation, and always returns immediately. The asynchronous
1565
- * operation will continue until one of the following conditions is true:
1566
- *
1567
- * @li The get area of the dynamic buffer sequence contains the specified
1568
- * delimiter.
1569
- *
1570
- * @li An error occurred.
1571
- *
1572
- * This operation is implemented in terms of zero or more calls to the stream's
1573
- * async_read_some function, and is known as a <em>composed operation</em>. If
1574
- * the dynamic buffer sequence's get area already contains the delimiter, this
1575
- * asynchronous operation completes immediately. The program must ensure that
1576
- * the stream performs no other read operations (such as async_read,
1577
- * async_read_until, the stream's async_read_some function, or any other
1578
- * composed operations that perform reads) until this operation completes.
1579
- *
1580
- * @param s The stream from which the data is to be read. The type must support
1581
- * the AsyncReadStream concept.
1582
- *
1583
- * @param buffers The dynamic buffer sequence into which the data will be read.
1584
- * Although the buffers object may be copied as necessary, ownership of the
1585
- * underlying memory blocks is retained by the caller, which must guarantee
1586
- * that they remain valid until the completion handler is called.
1587
- *
1588
- * @param delim The delimiter character.
1589
- *
1590
- * @param token The @ref completion_token that will be used to produce a
1591
- * completion handler, which will be called when the read completes.
1592
- * Potential completion tokens include @ref use_future, @ref use_awaitable,
1593
- * @ref yield_context, or a function object with the correct completion
1594
- * signature. The function signature of the completion handler must be:
1595
- * @code void handler(
1596
- * // Result of operation.
1597
- * const boost::system::error_code& error,
1598
- *
1599
- * // The number of bytes in the dynamic buffer sequence's
1600
- * // get area up to and including the delimiter.
1601
- * std::size_t bytes_transferred
1602
- * ); @endcode
1603
- * Regardless of whether the asynchronous operation completes immediately or
1604
- * not, the completion handler will not be invoked from within this function.
1605
- * On immediate completion, invocation of the handler will be performed in a
1606
- * manner equivalent to using boost::asio::async_immediate().
1607
- *
1608
- * @par Completion Signature
1609
- * @code void(boost::system::error_code, std::size_t) @endcode
1610
- *
1611
- * @note After a successful async_read_until operation, the dynamic buffer
1612
- * sequence may contain additional data beyond the delimiter. An application
1613
- * will typically leave that data in the dynamic buffer sequence for a
1614
- * subsequent async_read_until operation to examine.
1615
- *
1616
- * @par Example
1617
- * To asynchronously read data into a @c std::string until a newline is
1618
- * encountered:
1619
- * @code std::string data;
1620
- * ...
1621
- * void handler(const boost::system::error_code& e, std::size_t size)
1622
- * {
1623
- * if (!e)
1624
- * {
1625
- * std::string line = data.substr(0, n);
1626
- * data.erase(0, n);
1627
- * ...
1628
- * }
1629
- * }
1630
- * ...
1631
- * boost::asio::async_read_until(s, data, '\n', handler); @endcode
1632
- * After the @c async_read_until operation completes successfully, the buffer
1633
- * @c data contains the delimiter:
1634
- * @code { 'a', 'b', ..., 'c', '\n', 'd', 'e', ... } @endcode
1635
- * The call to @c substr then extracts the data up to and including the
1636
- * delimiter, so that the string @c line contains:
1637
- * @code { 'a', 'b', ..., 'c', '\n' } @endcode
1638
- * After the call to @c erase, the remaining data is left in the buffer @c data
1639
- * as follows:
1640
- * @code { 'd', 'e', ... } @endcode
1641
- * This data may be the start of a new line, to be extracted by a subsequent
1642
- * @c async_read_until operation.
1643
- *
1644
- * @par Per-Operation Cancellation
1645
- * This asynchronous operation supports cancellation for the following
1646
- * boost::asio::cancellation_type values:
1647
- *
1648
- * @li @c cancellation_type::terminal
1649
- *
1650
- * @li @c cancellation_type::partial
1651
- *
1652
- * if they are also supported by the @c AsyncReadStream type's
1653
- * @c async_read_some operation.
1654
- */
1655
- template <typename AsyncReadStream, typename DynamicBuffer_v1,
1656
- BOOST_ASIO_COMPLETION_TOKEN_FOR(void (boost::system::error_code,
1657
- std::size_t)) ReadToken = default_completion_token_t<
1658
- typename AsyncReadStream::executor_type>>
1659
- inline auto async_read_until(AsyncReadStream& s,
1660
- DynamicBuffer_v1&& buffers, char delim,
1661
- ReadToken&& token = default_completion_token_t<
1662
- typename AsyncReadStream::executor_type>(),
1663
- constraint_t<
1664
- is_dynamic_buffer_v1<decay_t<DynamicBuffer_v1>>::value
1665
- > = 0,
1666
- constraint_t<
1667
- !is_dynamic_buffer_v2<decay_t<DynamicBuffer_v1>>::value
1668
- > = 0)
1669
- -> decltype(
1670
- async_initiate<ReadToken,
1671
- void (boost::system::error_code, std::size_t)>(
1672
- declval<detail::initiate_async_read_until_delim_v1<AsyncReadStream>>(),
1673
- token, static_cast<DynamicBuffer_v1&&>(buffers), delim))
1674
- {
1675
- return async_initiate<ReadToken,
1676
- void (boost::system::error_code, std::size_t)>(
1677
- detail::initiate_async_read_until_delim_v1<AsyncReadStream>(s),
1678
- token, static_cast<DynamicBuffer_v1&&>(buffers), delim);
1679
- }
1680
-
1681
- /// Start an asynchronous operation to read data into a dynamic buffer sequence
1682
- /// until it contains a specified delimiter.
1683
- /**
1684
- * This function is used to asynchronously read data into the specified dynamic
1685
- * buffer sequence until the dynamic buffer sequence's get area contains the
1686
- * specified delimiter. It is an initiating function for an @ref
1687
- * asynchronous_operation, and always returns immediately. The asynchronous
1688
- * operation will continue until one of the following conditions is true:
1689
- *
1690
- * @li The get area of the dynamic buffer sequence contains the specified
1691
- * delimiter.
1692
- *
1693
- * @li An error occurred.
1694
- *
1695
- * This operation is implemented in terms of zero or more calls to the stream's
1696
- * async_read_some function, and is known as a <em>composed operation</em>. If
1697
- * the dynamic buffer sequence's get area already contains the delimiter, this
1698
- * asynchronous operation completes immediately. The program must ensure that
1699
- * the stream performs no other read operations (such as async_read,
1700
- * async_read_until, the stream's async_read_some function, or any other
1701
- * composed operations that perform reads) until this operation completes.
1702
- *
1703
- * @param s The stream from which the data is to be read. The type must support
1704
- * the AsyncReadStream concept.
1705
- *
1706
- * @param buffers The dynamic buffer sequence into which the data will be read.
1707
- * Although the buffers object may be copied as necessary, ownership of the
1708
- * underlying memory blocks is retained by the caller, which must guarantee
1709
- * that they remain valid until the completion handler is called.
1710
- *
1711
- * @param delim The delimiter string.
1712
- *
1713
- * @param token The @ref completion_token that will be used to produce a
1714
- * completion handler, which will be called when the read completes.
1715
- * Potential completion tokens include @ref use_future, @ref use_awaitable,
1716
- * @ref yield_context, or a function object with the correct completion
1717
- * signature. The function signature of the completion handler must be:
1718
- * @code void handler(
1719
- * // Result of operation.
1720
- * const boost::system::error_code& error,
1721
- *
1722
- * // The number of bytes in the dynamic buffer sequence's
1723
- * // get area up to and including the delimiter.
1724
- * std::size_t bytes_transferred
1725
- * ); @endcode
1726
- * Regardless of whether the asynchronous operation completes immediately or
1727
- * not, the completion handler will not be invoked from within this function.
1728
- * On immediate completion, invocation of the handler will be performed in a
1729
- * manner equivalent to using boost::asio::async_immediate().
1730
- *
1731
- * @par Completion Signature
1732
- * @code void(boost::system::error_code, std::size_t) @endcode
1733
- *
1734
- * @note After a successful async_read_until operation, the dynamic buffer
1735
- * sequence may contain additional data beyond the delimiter. An application
1736
- * will typically leave that data in the dynamic buffer sequence for a
1737
- * subsequent async_read_until operation to examine.
1738
- *
1739
- * @par Example
1740
- * To asynchronously read data into a @c std::string until a CR-LF sequence is
1741
- * encountered:
1742
- * @code std::string data;
1743
- * ...
1744
- * void handler(const boost::system::error_code& e, std::size_t size)
1745
- * {
1746
- * if (!e)
1747
- * {
1748
- * std::string line = data.substr(0, n);
1749
- * data.erase(0, n);
1750
- * ...
1751
- * }
1752
- * }
1753
- * ...
1754
- * boost::asio::async_read_until(s, data, "\r\n", handler); @endcode
1755
- * After the @c async_read_until operation completes successfully, the string
1756
- * @c data contains the delimiter:
1757
- * @code { 'a', 'b', ..., 'c', '\r', '\n', 'd', 'e', ... } @endcode
1758
- * The call to @c substr then extracts the data up to and including the
1759
- * delimiter, so that the string @c line contains:
1760
- * @code { 'a', 'b', ..., 'c', '\r', '\n' } @endcode
1761
- * After the call to @c erase, the remaining data is left in the string @c data
1762
- * as follows:
1763
- * @code { 'd', 'e', ... } @endcode
1764
- * This data may be the start of a new line, to be extracted by a subsequent
1765
- * @c async_read_until operation.
1766
- *
1767
- * @par Per-Operation Cancellation
1768
- * This asynchronous operation supports cancellation for the following
1769
- * boost::asio::cancellation_type values:
1770
- *
1771
- * @li @c cancellation_type::terminal
1772
- *
1773
- * @li @c cancellation_type::partial
1774
- *
1775
- * if they are also supported by the @c AsyncReadStream type's
1776
- * @c async_read_some operation.
1777
- */
1778
- template <typename AsyncReadStream, typename DynamicBuffer_v1,
1779
- BOOST_ASIO_COMPLETION_TOKEN_FOR(void (boost::system::error_code,
1780
- std::size_t)) ReadToken = default_completion_token_t<
1781
- typename AsyncReadStream::executor_type>>
1782
- inline auto async_read_until(AsyncReadStream& s,
1783
- DynamicBuffer_v1&& buffers,
1784
- BOOST_ASIO_STRING_VIEW_PARAM delim,
1785
- ReadToken&& token = default_completion_token_t<
1786
- typename AsyncReadStream::executor_type>(),
1787
- constraint_t<
1788
- is_dynamic_buffer_v1<decay_t<DynamicBuffer_v1>>::value
1789
- > = 0,
1790
- constraint_t<
1791
- !is_dynamic_buffer_v2<decay_t<DynamicBuffer_v1>>::value
1792
- > = 0)
1793
- -> decltype(
1794
- async_initiate<ReadToken,
1795
- void (boost::system::error_code, std::size_t)>(
1796
- declval<detail::initiate_async_read_until_delim_string_v1<
1797
- AsyncReadStream>>(),
1798
- token, static_cast<DynamicBuffer_v1&&>(buffers),
1799
- static_cast<std::string>(delim)))
1800
- {
1801
- return async_initiate<ReadToken,
1802
- void (boost::system::error_code, std::size_t)>(
1803
- detail::initiate_async_read_until_delim_string_v1<AsyncReadStream>(s),
1804
- token, static_cast<DynamicBuffer_v1&&>(buffers),
1805
- static_cast<std::string>(delim));
1806
- }
1807
-
1808
- #if !defined(BOOST_ASIO_NO_EXTENSIONS)
1809
- #if defined(BOOST_ASIO_HAS_BOOST_REGEX) \
1810
- || defined(GENERATING_DOCUMENTATION)
1811
-
1812
- /// Start an asynchronous operation to read data into a dynamic buffer sequence
1813
- /// until some part of its data matches a regular expression.
1814
- /**
1815
- * This function is used to asynchronously read data into the specified dynamic
1816
- * buffer sequence until the dynamic buffer sequence's get area contains some
1817
- * data that matches a regular expression. It is an initiating function for an
1818
- * @ref asynchronous_operation, and always returns immediately. The
1819
- * asynchronous operation will continue until one of the following conditions
1820
- * is true:
1821
- *
1822
- * @li A substring of the dynamic buffer sequence's get area matches the regular
1823
- * expression.
1824
- *
1825
- * @li An error occurred.
1826
- *
1827
- * This operation is implemented in terms of zero or more calls to the stream's
1828
- * async_read_some function, and is known as a <em>composed operation</em>. If
1829
- * the dynamic buffer sequence's get area already contains data that matches
1830
- * the regular expression, this asynchronous operation completes immediately.
1831
- * The program must ensure that the stream performs no other read operations
1832
- * (such as async_read, async_read_until, the stream's async_read_some
1833
- * function, or any other composed operations that perform reads) until this
1834
- * operation completes.
1835
- *
1836
- * @param s The stream from which the data is to be read. The type must support
1837
- * the AsyncReadStream concept.
1838
- *
1839
- * @param buffers The dynamic buffer sequence into which the data will be read.
1840
- * Although the buffers object may be copied as necessary, ownership of the
1841
- * underlying memory blocks is retained by the caller, which must guarantee
1842
- * that they remain valid until the completion handler is called.
1843
- *
1844
- * @param expr The regular expression.
1845
- *
1846
- * @param token The @ref completion_token that will be used to produce a
1847
- * completion handler, which will be called when the read completes.
1848
- * Potential completion tokens include @ref use_future, @ref use_awaitable,
1849
- * @ref yield_context, or a function object with the correct completion
1850
- * signature. The function signature of the completion handler must be:
1851
- * @code void handler(
1852
- * // Result of operation.
1853
- * const boost::system::error_code& error,
1854
- *
1855
- * // The number of bytes in the dynamic buffer
1856
- * // sequence's get area up to and including the
1857
- * // substring that matches the regular expression.
1858
- * // 0 if an error occurred.
1859
- * std::size_t bytes_transferred
1860
- * ); @endcode
1861
- * Regardless of whether the asynchronous operation completes immediately or
1862
- * not, the completion handler will not be invoked from within this function.
1863
- * On immediate completion, invocation of the handler will be performed in a
1864
- * manner equivalent to using boost::asio::async_immediate().
1865
- *
1866
- * @par Completion Signature
1867
- * @code void(boost::system::error_code, std::size_t) @endcode
1868
- *
1869
- * @note After a successful async_read_until operation, the dynamic buffer
1870
- * sequence may contain additional data beyond that which matched the regular
1871
- * expression. An application will typically leave that data in the dynamic
1872
- * buffer sequence for a subsequent async_read_until operation to examine.
1873
- *
1874
- * @par Example
1875
- * To asynchronously read data into a @c std::string until a CR-LF sequence is
1876
- * encountered:
1877
- * @code std::string data;
1878
- * ...
1879
- * void handler(const boost::system::error_code& e, std::size_t size)
1880
- * {
1881
- * if (!e)
1882
- * {
1883
- * std::string line = data.substr(0, n);
1884
- * data.erase(0, n);
1885
- * ...
1886
- * }
1887
- * }
1888
- * ...
1889
- * boost::asio::async_read_until(s, data,
1890
- * boost::regex("\r\n"), handler); @endcode
1891
- * After the @c async_read_until operation completes successfully, the string
1892
- * @c data contains the data which matched the regular expression:
1893
- * @code { 'a', 'b', ..., 'c', '\r', '\n', 'd', 'e', ... } @endcode
1894
- * The call to @c substr then extracts the data up to and including the match,
1895
- * so that the string @c line contains:
1896
- * @code { 'a', 'b', ..., 'c', '\r', '\n' } @endcode
1897
- * After the call to @c erase, the remaining data is left in the string @c data
1898
- * as follows:
1899
- * @code { 'd', 'e', ... } @endcode
1900
- * This data may be the start of a new line, to be extracted by a subsequent
1901
- * @c async_read_until operation.
1902
- *
1903
- * @par Per-Operation Cancellation
1904
- * This asynchronous operation supports cancellation for the following
1905
- * boost::asio::cancellation_type values:
1906
- *
1907
- * @li @c cancellation_type::terminal
1908
- *
1909
- * @li @c cancellation_type::partial
1910
- *
1911
- * if they are also supported by the @c AsyncReadStream type's
1912
- * @c async_read_some operation.
1913
- */
1914
- template <typename AsyncReadStream, typename DynamicBuffer_v1, typename Traits,
1915
- BOOST_ASIO_COMPLETION_TOKEN_FOR(void (boost::system::error_code,
1916
- std::size_t)) ReadToken = default_completion_token_t<
1917
- typename AsyncReadStream::executor_type>>
1918
- inline auto async_read_until(AsyncReadStream& s, DynamicBuffer_v1&& buffers,
1919
- const boost::basic_regex<char, Traits>& expr,
1920
- ReadToken&& token = default_completion_token_t<
1921
- typename AsyncReadStream::executor_type>(),
1922
- constraint_t<
1923
- is_dynamic_buffer_v1<decay_t<DynamicBuffer_v1>>::value
1924
- > = 0,
1925
- constraint_t<
1926
- !is_dynamic_buffer_v2<decay_t<DynamicBuffer_v1>>::value
1927
- > = 0)
1928
- -> decltype(
1929
- async_initiate<ReadToken,
1930
- void (boost::system::error_code, std::size_t)>(
1931
- declval<detail::initiate_async_read_until_expr_v1<AsyncReadStream>>(),
1932
- token, static_cast<DynamicBuffer_v1&&>(buffers), expr))
1933
- {
1934
- return async_initiate<ReadToken,
1935
- void (boost::system::error_code, std::size_t)>(
1936
- detail::initiate_async_read_until_expr_v1<AsyncReadStream>(s),
1937
- token, static_cast<DynamicBuffer_v1&&>(buffers), expr);
1938
- }
1939
-
1940
- #endif // defined(BOOST_ASIO_HAS_BOOST_REGEX)
1941
- // || defined(GENERATING_DOCUMENTATION)
1942
-
1943
- /// Start an asynchronous operation to read data into a dynamic buffer sequence
1944
- /// until a function object indicates a match.
1945
- /**
1946
- * This function is used to asynchronously read data into the specified dynamic
1947
- * buffer sequence until a user-defined match condition function object, when
1948
- * applied to the data contained in the dynamic buffer sequence, indicates a
1949
- * successful match. It is an initiating function for an @ref
1950
- * asynchronous_operation, and always returns immediately. The asynchronous
1951
- * operation will continue until one of the following conditions is true:
1952
- *
1953
- * @li The match condition function object returns a std::pair where the second
1954
- * element evaluates to true.
1955
- *
1956
- * @li An error occurred.
1957
- *
1958
- * This operation is implemented in terms of zero or more calls to the stream's
1959
- * async_read_some function, and is known as a <em>composed operation</em>. If
1960
- * the match condition function object already indicates a match, this
1961
- * asynchronous operation completes immediately. The program must ensure that
1962
- * the stream performs no other read operations (such as async_read,
1963
- * async_read_until, the stream's async_read_some function, or any other
1964
- * composed operations that perform reads) until this operation completes.
1965
- *
1966
- * @param s The stream from which the data is to be read. The type must support
1967
- * the AsyncReadStream concept.
1968
- *
1969
- * @param buffers The dynamic buffer sequence into which the data will be read.
1970
- * Although the buffers object may be copied as necessary, ownership of the
1971
- * underlying memory blocks is retained by the caller, which must guarantee
1972
- * that they remain valid until the completion handler is called.
1973
- *
1974
- * @param match_condition The function object to be called to determine whether
1975
- * a match exists. The signature of the function object must be:
1976
- * @code pair<iterator, bool> match_condition(iterator begin, iterator end);
1977
- * @endcode
1978
- * where @c iterator represents the type:
1979
- * @code buffers_iterator<typename DynamicBuffer_v1::const_buffers_type>
1980
- * @endcode
1981
- * The iterator parameters @c begin and @c end define the range of bytes to be
1982
- * scanned to determine whether there is a match. The @c first member of the
1983
- * return value is an iterator marking one-past-the-end of the bytes that have
1984
- * been consumed by the match function. This iterator is used to calculate the
1985
- * @c begin parameter for any subsequent invocation of the match condition. The
1986
- * @c second member of the return value is true if a match has been found, false
1987
- * otherwise.
1988
- *
1989
- * @param token The @ref completion_token that will be used to produce a
1990
- * completion handler, which will be called when the read completes.
1991
- * Potential completion tokens include @ref use_future, @ref use_awaitable,
1992
- * @ref yield_context, or a function object with the correct completion
1993
- * signature. The function signature of the completion handler must be:
1994
- * @code void handler(
1995
- * // Result of operation.
1996
- * const boost::system::error_code& error,
1997
- *
1998
- * // The number of bytes in the dynamic buffer sequence's
1999
- * // get area that have been fully consumed by the match
2000
- * // function. O if an error occurred.
2001
- * std::size_t bytes_transferred
2002
- * ); @endcode
2003
- * Regardless of whether the asynchronous operation completes immediately or
2004
- * not, the completion handler will not be invoked from within this function.
2005
- * On immediate completion, invocation of the handler will be performed in a
2006
- * manner equivalent to using boost::asio::async_immediate().
2007
- *
2008
- * @note After a successful async_read_until operation, the dynamic buffer
2009
- * sequence may contain additional data beyond that which matched the function
2010
- * object. An application will typically leave that data in the dynamic buffer
2011
- * sequence for a subsequent async_read_until operation to examine.
2012
- *
2013
- * @par Completion Signature
2014
- * @code void(boost::system::error_code, std::size_t) @endcode
2015
- *
2016
- * @note The default implementation of the @c is_match_condition type trait
2017
- * evaluates to true for function pointers and function objects with a
2018
- * @c result_type typedef. It must be specialised for other user-defined
2019
- * function objects.
2020
- *
2021
- * @par Examples
2022
- * To asynchronously read data into a @c std::string until whitespace is
2023
- * encountered:
2024
- * @code typedef boost::asio::buffers_iterator<
2025
- * boost::asio::const_buffers_1> iterator;
2026
- *
2027
- * std::pair<iterator, bool>
2028
- * match_whitespace(iterator begin, iterator end)
2029
- * {
2030
- * iterator i = begin;
2031
- * while (i != end)
2032
- * if (std::isspace(*i++))
2033
- * return std::make_pair(i, true);
2034
- * return std::make_pair(i, false);
2035
- * }
2036
- * ...
2037
- * void handler(const boost::system::error_code& e, std::size_t size);
2038
- * ...
2039
- * std::string data;
2040
- * boost::asio::async_read_until(s, data, match_whitespace, handler);
2041
- * @endcode
2042
- *
2043
- * To asynchronously read data into a @c std::string until a matching character
2044
- * is found:
2045
- * @code class match_char
2046
- * {
2047
- * public:
2048
- * explicit match_char(char c) : c_(c) {}
2049
- *
2050
- * template <typename Iterator>
2051
- * std::pair<Iterator, bool> operator()(
2052
- * Iterator begin, Iterator end) const
2053
- * {
2054
- * Iterator i = begin;
2055
- * while (i != end)
2056
- * if (c_ == *i++)
2057
- * return std::make_pair(i, true);
2058
- * return std::make_pair(i, false);
2059
- * }
2060
- *
2061
- * private:
2062
- * char c_;
2063
- * };
2064
- *
2065
- * namespace asio {
2066
- * template <> struct is_match_condition<match_char>
2067
- * : public boost::true_type {};
2068
- * } // namespace asio
2069
- * ...
2070
- * void handler(const boost::system::error_code& e, std::size_t size);
2071
- * ...
2072
- * std::string data;
2073
- * boost::asio::async_read_until(s, data, match_char('a'), handler);
2074
- * @endcode
2075
- *
2076
- * @par Per-Operation Cancellation
2077
- * This asynchronous operation supports cancellation for the following
2078
- * boost::asio::cancellation_type values:
2079
- *
2080
- * @li @c cancellation_type::terminal
2081
- *
2082
- * @li @c cancellation_type::partial
2083
- *
2084
- * if they are also supported by the @c AsyncReadStream type's
2085
- * @c async_read_some operation.
2086
- */
2087
- template <typename AsyncReadStream,
2088
- typename DynamicBuffer_v1, typename MatchCondition,
2089
- BOOST_ASIO_COMPLETION_TOKEN_FOR(void (boost::system::error_code,
2090
- std::size_t)) ReadToken = default_completion_token_t<
2091
- typename AsyncReadStream::executor_type>>
2092
- inline auto async_read_until(AsyncReadStream& s,
2093
- DynamicBuffer_v1&& buffers, MatchCondition match_condition,
2094
- ReadToken&& token = default_completion_token_t<
2095
- typename AsyncReadStream::executor_type>(),
2096
- constraint_t<
2097
- is_match_condition<MatchCondition>::value
2098
- > = 0,
2099
- constraint_t<
2100
- is_dynamic_buffer_v1<decay_t<DynamicBuffer_v1>>::value
2101
- > = 0,
2102
- constraint_t<
2103
- !is_dynamic_buffer_v2<decay_t<DynamicBuffer_v1>>::value
2104
- > = 0)
2105
- -> decltype(
2106
- async_initiate<ReadToken,
2107
- void (boost::system::error_code, std::size_t)>(
2108
- declval<detail::initiate_async_read_until_match_v1<AsyncReadStream>>(),
2109
- token, static_cast<DynamicBuffer_v1&&>(buffers),
2110
- match_condition))
2111
- {
2112
- return async_initiate<ReadToken,
2113
- void (boost::system::error_code, std::size_t)>(
2114
- detail::initiate_async_read_until_match_v1<AsyncReadStream>(s),
2115
- token, static_cast<DynamicBuffer_v1&&>(buffers),
2116
- match_condition);
2117
- }
2118
-
2119
- #if !defined(BOOST_ASIO_NO_IOSTREAM)
2120
-
2121
- /// Start an asynchronous operation to read data into a streambuf until it
2122
- /// contains a specified delimiter.
2123
- /**
2124
- * This function is used to asynchronously read data into the specified
2125
- * streambuf until the streambuf's get area contains the specified delimiter.
2126
- * It is an initiating function for an @ref asynchronous_operation, and always
2127
- * returns immediately. The asynchronous operation will continue until one of
2128
- * the following conditions is true:
2129
- *
2130
- * @li The get area of the streambuf contains the specified delimiter.
2131
- *
2132
- * @li An error occurred.
2133
- *
2134
- * This operation is implemented in terms of zero or more calls to the stream's
2135
- * async_read_some function, and is known as a <em>composed operation</em>. If
2136
- * the streambuf's get area already contains the delimiter, this asynchronous
2137
- * operation completes immediately. The program must ensure that the stream
2138
- * performs no other read operations (such as async_read, async_read_until, the
2139
- * stream's async_read_some function, or any other composed operations that
2140
- * perform reads) until this operation completes.
2141
- *
2142
- * @param s The stream from which the data is to be read. The type must support
2143
- * the AsyncReadStream concept.
2144
- *
2145
- * @param b A streambuf object into which the data will be read. Ownership of
2146
- * the streambuf is retained by the caller, which must guarantee that it remains
2147
- * valid until the completion handler is called.
2148
- *
2149
- * @param delim The delimiter character.
2150
- *
2151
- * @param token The @ref completion_token that will be used to produce a
2152
- * completion handler, which will be called when the read completes.
2153
- * Potential completion tokens include @ref use_future, @ref use_awaitable,
2154
- * @ref yield_context, or a function object with the correct completion
2155
- * signature. The function signature of the completion handler must be:
2156
- * @code void handler(
2157
- * // Result of operation.
2158
- * const boost::system::error_code& error,
2159
- *
2160
- * // The number of bytes in the streambuf's get
2161
- * // area up to and including the delimiter.
2162
- * // 0 if an error occurred.
2163
- * std::size_t bytes_transferred
2164
- * ); @endcode
2165
- * Regardless of whether the asynchronous operation completes immediately or
2166
- * not, the completion handler will not be invoked from within this function.
2167
- * On immediate completion, invocation of the handler will be performed in a
2168
- * manner equivalent to using boost::asio::async_immediate().
2169
- *
2170
- * @par Completion Signature
2171
- * @code void(boost::system::error_code, std::size_t) @endcode
2172
- *
2173
- * @note After a successful async_read_until operation, the streambuf may
2174
- * contain additional data beyond the delimiter. An application will typically
2175
- * leave that data in the streambuf for a subsequent async_read_until operation
2176
- * to examine.
2177
- *
2178
- * @par Example
2179
- * To asynchronously read data into a streambuf until a newline is encountered:
2180
- * @code boost::asio::streambuf b;
2181
- * ...
2182
- * void handler(const boost::system::error_code& e, std::size_t size)
2183
- * {
2184
- * if (!e)
2185
- * {
2186
- * std::istream is(&b);
2187
- * std::string line;
2188
- * std::getline(is, line);
2189
- * ...
2190
- * }
2191
- * }
2192
- * ...
2193
- * boost::asio::async_read_until(s, b, '\n', handler); @endcode
2194
- * After the @c async_read_until operation completes successfully, the buffer
2195
- * @c b contains the delimiter:
2196
- * @code { 'a', 'b', ..., 'c', '\n', 'd', 'e', ... } @endcode
2197
- * The call to @c std::getline then extracts the data up to and including the
2198
- * newline (which is discarded), so that the string @c line contains:
2199
- * @code { 'a', 'b', ..., 'c' } @endcode
2200
- * The remaining data is left in the buffer @c b as follows:
2201
- * @code { 'd', 'e', ... } @endcode
2202
- * This data may be the start of a new line, to be extracted by a subsequent
2203
- * @c async_read_until operation.
2204
- *
2205
- * @par Per-Operation Cancellation
2206
- * This asynchronous operation supports cancellation for the following
2207
- * boost::asio::cancellation_type values:
2208
- *
2209
- * @li @c cancellation_type::terminal
2210
- *
2211
- * @li @c cancellation_type::partial
2212
- *
2213
- * if they are also supported by the @c AsyncReadStream type's
2214
- * @c async_read_some operation.
2215
- */
2216
- template <typename AsyncReadStream, typename Allocator,
2217
- BOOST_ASIO_COMPLETION_TOKEN_FOR(void (boost::system::error_code,
2218
- std::size_t)) ReadToken = default_completion_token_t<
2219
- typename AsyncReadStream::executor_type>>
2220
- inline auto async_read_until(AsyncReadStream& s,
2221
- boost::asio::basic_streambuf<Allocator>& b, char delim,
2222
- ReadToken&& token = default_completion_token_t<
2223
- typename AsyncReadStream::executor_type>())
2224
- -> decltype(
2225
- async_initiate<ReadToken,
2226
- void (boost::system::error_code, std::size_t)>(
2227
- declval<detail::initiate_async_read_until_delim_v1<AsyncReadStream>>(),
2228
- token, basic_streambuf_ref<Allocator>(b), delim))
2229
- {
2230
- return async_initiate<ReadToken,
2231
- void (boost::system::error_code, std::size_t)>(
2232
- detail::initiate_async_read_until_delim_v1<AsyncReadStream>(s),
2233
- token, basic_streambuf_ref<Allocator>(b), delim);
2234
- }
2235
-
2236
- /// Start an asynchronous operation to read data into a streambuf until it
2237
- /// contains a specified delimiter.
2238
- /**
2239
- * This function is used to asynchronously read data into the specified
2240
- * streambuf until the streambuf's get area contains the specified delimiter.
2241
- * It is an initiating function for an @ref asynchronous_operation, and always
2242
- * returns immediately. The asynchronous operation will continue until one of
2243
- * the following conditions is true:
2244
- *
2245
- * @li The get area of the streambuf contains the specified delimiter.
2246
- *
2247
- * @li An error occurred.
2248
- *
2249
- * This operation is implemented in terms of zero or more calls to the stream's
2250
- * async_read_some function, and is known as a <em>composed operation</em>. If
2251
- * the streambuf's get area already contains the delimiter, this asynchronous
2252
- * operation completes immediately. The program must ensure that the stream
2253
- * performs no other read operations (such as async_read, async_read_until, the
2254
- * stream's async_read_some function, or any other composed operations that
2255
- * perform reads) until this operation completes.
2256
- *
2257
- * @param s The stream from which the data is to be read. The type must support
2258
- * the AsyncReadStream concept.
2259
- *
2260
- * @param b A streambuf object into which the data will be read. Ownership of
2261
- * the streambuf is retained by the caller, which must guarantee that it remains
2262
- * valid until the completion handler is called.
2263
- *
2264
- * @param delim The delimiter string.
2265
- *
2266
- * @param token The @ref completion_token that will be used to produce a
2267
- * completion handler, which will be called when the read completes.
2268
- * Potential completion tokens include @ref use_future, @ref use_awaitable,
2269
- * @ref yield_context, or a function object with the correct completion
2270
- * signature. The function signature of the completion handler must be:
2271
- * @code void handler(
2272
- * // Result of operation.
2273
- * const boost::system::error_code& error,
2274
- *
2275
- * // The number of bytes in the streambuf's get
2276
- * // area up to and including the delimiter.
2277
- * // 0 if an error occurred.
2278
- * std::size_t bytes_transferred
2279
- * ); @endcode
2280
- * Regardless of whether the asynchronous operation completes immediately or
2281
- * not, the completion handler will not be invoked from within this function.
2282
- * On immediate completion, invocation of the handler will be performed in a
2283
- * manner equivalent to using boost::asio::async_immediate().
2284
- *
2285
- * @par Completion Signature
2286
- * @code void(boost::system::error_code, std::size_t) @endcode
2287
- *
2288
- * @note After a successful async_read_until operation, the streambuf may
2289
- * contain additional data beyond the delimiter. An application will typically
2290
- * leave that data in the streambuf for a subsequent async_read_until operation
2291
- * to examine.
2292
- *
2293
- * @par Example
2294
- * To asynchronously read data into a streambuf until a newline is encountered:
2295
- * @code boost::asio::streambuf b;
2296
- * ...
2297
- * void handler(const boost::system::error_code& e, std::size_t size)
2298
- * {
2299
- * if (!e)
2300
- * {
2301
- * std::istream is(&b);
2302
- * std::string line;
2303
- * std::getline(is, line);
2304
- * ...
2305
- * }
2306
- * }
2307
- * ...
2308
- * boost::asio::async_read_until(s, b, "\r\n", handler); @endcode
2309
- * After the @c async_read_until operation completes successfully, the buffer
2310
- * @c b contains the delimiter:
2311
- * @code { 'a', 'b', ..., 'c', '\r', '\n', 'd', 'e', ... } @endcode
2312
- * The call to @c std::getline then extracts the data up to and including the
2313
- * newline (which is discarded), so that the string @c line contains:
2314
- * @code { 'a', 'b', ..., 'c', '\r' } @endcode
2315
- * The remaining data is left in the buffer @c b as follows:
2316
- * @code { 'd', 'e', ... } @endcode
2317
- * This data may be the start of a new line, to be extracted by a subsequent
2318
- * @c async_read_until operation.
2319
- *
2320
- * @par Per-Operation Cancellation
2321
- * This asynchronous operation supports cancellation for the following
2322
- * boost::asio::cancellation_type values:
2323
- *
2324
- * @li @c cancellation_type::terminal
2325
- *
2326
- * @li @c cancellation_type::partial
2327
- *
2328
- * if they are also supported by the @c AsyncReadStream type's
2329
- * @c async_read_some operation.
2330
- */
2331
- template <typename AsyncReadStream, typename Allocator,
2332
- BOOST_ASIO_COMPLETION_TOKEN_FOR(void (boost::system::error_code,
2333
- std::size_t)) ReadToken = default_completion_token_t<
2334
- typename AsyncReadStream::executor_type>>
2335
- inline auto async_read_until(AsyncReadStream& s,
2336
- boost::asio::basic_streambuf<Allocator>& b,
2337
- BOOST_ASIO_STRING_VIEW_PARAM delim,
2338
- ReadToken&& token = default_completion_token_t<
2339
- typename AsyncReadStream::executor_type>())
2340
- -> decltype(
2341
- async_initiate<ReadToken,
2342
- void (boost::system::error_code, std::size_t)>(
2343
- declval<detail::initiate_async_read_until_delim_string_v1<
2344
- AsyncReadStream>>(),
2345
- token, basic_streambuf_ref<Allocator>(b),
2346
- static_cast<std::string>(delim)))
2347
- {
2348
- return async_initiate<ReadToken,
2349
- void (boost::system::error_code, std::size_t)>(
2350
- detail::initiate_async_read_until_delim_string_v1<AsyncReadStream>(s),
2351
- token, basic_streambuf_ref<Allocator>(b),
2352
- static_cast<std::string>(delim));
2353
- }
2354
-
2355
- #if defined(BOOST_ASIO_HAS_BOOST_REGEX) \
2356
- || defined(GENERATING_DOCUMENTATION)
2357
-
2358
- /// Start an asynchronous operation to read data into a streambuf until some
2359
- /// part of its data matches a regular expression.
2360
- /**
2361
- * This function is used to asynchronously read data into the specified
2362
- * streambuf until the streambuf's get area contains some data that matches a
2363
- * regular expression. It is an initiating function for an @ref
2364
- * asynchronous_operation, and always returns immediately. The asynchronous
2365
- * operation will continue until one of the following conditions is true:
2366
- *
2367
- * @li A substring of the streambuf's get area matches the regular expression.
2368
- *
2369
- * @li An error occurred.
2370
- *
2371
- * This operation is implemented in terms of zero or more calls to the stream's
2372
- * async_read_some function, and is known as a <em>composed operation</em>. If
2373
- * the streambuf's get area already contains data that matches the regular
2374
- * expression, this asynchronous operation completes immediately. The program
2375
- * must ensure that the stream performs no other read operations (such as
2376
- * async_read, async_read_until, the stream's async_read_some function, or any
2377
- * other composed operations that perform reads) until this operation
2378
- * completes.
2379
- *
2380
- * @param s The stream from which the data is to be read. The type must support
2381
- * the AsyncReadStream concept.
2382
- *
2383
- * @param b A streambuf object into which the data will be read. Ownership of
2384
- * the streambuf is retained by the caller, which must guarantee that it remains
2385
- * valid until the completion handler is called.
2386
- *
2387
- * @param expr The regular expression.
2388
- *
2389
- * @param token The @ref completion_token that will be used to produce a
2390
- * completion handler, which will be called when the read completes.
2391
- * Potential completion tokens include @ref use_future, @ref use_awaitable,
2392
- * @ref yield_context, or a function object with the correct completion
2393
- * signature. The function signature of the completion handler must be:
2394
- * @code void handler(
2395
- * // Result of operation.
2396
- * const boost::system::error_code& error,
2397
- *
2398
- * // The number of bytes in the streambuf's get
2399
- * // area up to and including the substring
2400
- * // that matches the regular. expression.
2401
- * // 0 if an error occurred.
2402
- * std::size_t bytes_transferred
2403
- * ); @endcode
2404
- * Regardless of whether the asynchronous operation completes immediately or
2405
- * not, the completion handler will not be invoked from within this function.
2406
- * On immediate completion, invocation of the handler will be performed in a
2407
- * manner equivalent to using boost::asio::async_immediate().
2408
- *
2409
- * @par Completion Signature
2410
- * @code void(boost::system::error_code, std::size_t) @endcode
2411
- *
2412
- * @note After a successful async_read_until operation, the streambuf may
2413
- * contain additional data beyond that which matched the regular expression. An
2414
- * application will typically leave that data in the streambuf for a subsequent
2415
- * async_read_until operation to examine.
2416
- *
2417
- * @par Example
2418
- * To asynchronously read data into a streambuf until a CR-LF sequence is
2419
- * encountered:
2420
- * @code boost::asio::streambuf b;
2421
- * ...
2422
- * void handler(const boost::system::error_code& e, std::size_t size)
2423
- * {
2424
- * if (!e)
2425
- * {
2426
- * std::istream is(&b);
2427
- * std::string line;
2428
- * std::getline(is, line);
2429
- * ...
2430
- * }
2431
- * }
2432
- * ...
2433
- * boost::asio::async_read_until(s, b, boost::regex("\r\n"), handler); @endcode
2434
- * After the @c async_read_until operation completes successfully, the buffer
2435
- * @c b contains the data which matched the regular expression:
2436
- * @code { 'a', 'b', ..., 'c', '\r', '\n', 'd', 'e', ... } @endcode
2437
- * The call to @c std::getline then extracts the data up to and including the
2438
- * newline (which is discarded), so that the string @c line contains:
2439
- * @code { 'a', 'b', ..., 'c', '\r' } @endcode
2440
- * The remaining data is left in the buffer @c b as follows:
2441
- * @code { 'd', 'e', ... } @endcode
2442
- * This data may be the start of a new line, to be extracted by a subsequent
2443
- * @c async_read_until operation.
2444
- *
2445
- * @par Per-Operation Cancellation
2446
- * This asynchronous operation supports cancellation for the following
2447
- * boost::asio::cancellation_type values:
2448
- *
2449
- * @li @c cancellation_type::terminal
2450
- *
2451
- * @li @c cancellation_type::partial
2452
- *
2453
- * if they are also supported by the @c AsyncReadStream type's
2454
- * @c async_read_some operation.
2455
- */
2456
- template <typename AsyncReadStream, typename Allocator, typename Traits,
2457
- BOOST_ASIO_COMPLETION_TOKEN_FOR(void (boost::system::error_code,
2458
- std::size_t)) ReadToken = default_completion_token_t<
2459
- typename AsyncReadStream::executor_type>>
2460
- inline auto async_read_until(AsyncReadStream& s,
2461
- boost::asio::basic_streambuf<Allocator>& b,
2462
- const boost::basic_regex<char, Traits>& expr,
2463
- ReadToken&& token = default_completion_token_t<
2464
- typename AsyncReadStream::executor_type>())
2465
- -> decltype(
2466
- async_initiate<ReadToken,
2467
- void (boost::system::error_code, std::size_t)>(
2468
- declval<detail::initiate_async_read_until_expr_v1<AsyncReadStream>>(),
2469
- token, basic_streambuf_ref<Allocator>(b), expr))
2470
- {
2471
- return async_initiate<ReadToken,
2472
- void (boost::system::error_code, std::size_t)>(
2473
- detail::initiate_async_read_until_expr_v1<AsyncReadStream>(s),
2474
- token, basic_streambuf_ref<Allocator>(b), expr);
2475
- }
2476
-
2477
- #endif // defined(BOOST_ASIO_HAS_BOOST_REGEX)
2478
- // || defined(GENERATING_DOCUMENTATION)
2479
-
2480
- /// Start an asynchronous operation to read data into a streambuf until a
2481
- /// function object indicates a match.
2482
- /**
2483
- * This function is used to asynchronously read data into the specified
2484
- * streambuf until a user-defined match condition function object, when applied
2485
- * to the data contained in the streambuf, indicates a successful match. It is
2486
- * an initiating function for an @ref asynchronous_operation, and always
2487
- * returns immediately. The asynchronous operation will continue until one of
2488
- * the following conditions is true:
2489
- *
2490
- * @li The match condition function object returns a std::pair where the second
2491
- * element evaluates to true.
2492
- *
2493
- * @li An error occurred.
2494
- *
2495
- * This operation is implemented in terms of zero or more calls to the stream's
2496
- * async_read_some function, and is known as a <em>composed operation</em>. If
2497
- * the match condition function object already indicates a match, this
2498
- * asynchronous operation completes immediately. The program must ensure that
2499
- * the stream performs no other read operations (such as async_read,
2500
- * async_read_until, the stream's async_read_some function, or any other
2501
- * composed operations that perform reads) until this operation completes.
2502
- *
2503
- * @param s The stream from which the data is to be read. The type must support
2504
- * the AsyncReadStream concept.
2505
- *
2506
- * @param b A streambuf object into which the data will be read.
2507
- *
2508
- * @param match_condition The function object to be called to determine whether
2509
- * a match exists. The signature of the function object must be:
2510
- * @code pair<iterator, bool> match_condition(iterator begin, iterator end);
2511
- * @endcode
2512
- * where @c iterator represents the type:
2513
- * @code buffers_iterator<basic_streambuf<Allocator>::const_buffers_type>
2514
- * @endcode
2515
- * The iterator parameters @c begin and @c end define the range of bytes to be
2516
- * scanned to determine whether there is a match. The @c first member of the
2517
- * return value is an iterator marking one-past-the-end of the bytes that have
2518
- * been consumed by the match function. This iterator is used to calculate the
2519
- * @c begin parameter for any subsequent invocation of the match condition. The
2520
- * @c second member of the return value is true if a match has been found, false
2521
- * otherwise.
2522
- *
2523
- * @param token The @ref completion_token that will be used to produce a
2524
- * completion handler, which will be called when the read completes.
2525
- * Potential completion tokens include @ref use_future, @ref use_awaitable,
2526
- * @ref yield_context, or a function object with the correct completion
2527
- * signature. The function signature of the completion handler must be:
2528
- * @code void handler(
2529
- * // Result of operation.
2530
- * const boost::system::error_code& error,
2531
- *
2532
- * // The number of bytes in the streambuf's get
2533
- * // area that have been fully consumed by the
2534
- * // match function. O if an error occurred.
2535
- * std::size_t bytes_transferred
2536
- * ); @endcode
2537
- * Regardless of whether the asynchronous operation completes immediately or
2538
- * not, the completion handler will not be invoked from within this function.
2539
- * On immediate completion, invocation of the handler will be performed in a
2540
- * manner equivalent to using boost::asio::async_immediate().
2541
- *
2542
- * @note After a successful async_read_until operation, the streambuf may
2543
- * contain additional data beyond that which matched the function object. An
2544
- * application will typically leave that data in the streambuf for a subsequent
2545
- * async_read_until operation to examine.
2546
- *
2547
- * @par Completion Signature
2548
- * @code void(boost::system::error_code, std::size_t) @endcode
2549
- *
2550
- * @note The default implementation of the @c is_match_condition type trait
2551
- * evaluates to true for function pointers and function objects with a
2552
- * @c result_type typedef. It must be specialised for other user-defined
2553
- * function objects.
2554
- *
2555
- * @par Examples
2556
- * To asynchronously read data into a streambuf until whitespace is encountered:
2557
- * @code typedef boost::asio::buffers_iterator<
2558
- * boost::asio::streambuf::const_buffers_type> iterator;
2559
- *
2560
- * std::pair<iterator, bool>
2561
- * match_whitespace(iterator begin, iterator end)
2562
- * {
2563
- * iterator i = begin;
2564
- * while (i != end)
2565
- * if (std::isspace(*i++))
2566
- * return std::make_pair(i, true);
2567
- * return std::make_pair(i, false);
2568
- * }
2569
- * ...
2570
- * void handler(const boost::system::error_code& e, std::size_t size);
2571
- * ...
2572
- * boost::asio::streambuf b;
2573
- * boost::asio::async_read_until(s, b, match_whitespace, handler);
2574
- * @endcode
2575
- *
2576
- * To asynchronously read data into a streambuf until a matching character is
2577
- * found:
2578
- * @code class match_char
2579
- * {
2580
- * public:
2581
- * explicit match_char(char c) : c_(c) {}
2582
- *
2583
- * template <typename Iterator>
2584
- * std::pair<Iterator, bool> operator()(
2585
- * Iterator begin, Iterator end) const
2586
- * {
2587
- * Iterator i = begin;
2588
- * while (i != end)
2589
- * if (c_ == *i++)
2590
- * return std::make_pair(i, true);
2591
- * return std::make_pair(i, false);
2592
- * }
2593
- *
2594
- * private:
2595
- * char c_;
2596
- * };
2597
- *
2598
- * namespace asio {
2599
- * template <> struct is_match_condition<match_char>
2600
- * : public boost::true_type {};
2601
- * } // namespace asio
2602
- * ...
2603
- * void handler(const boost::system::error_code& e, std::size_t size);
2604
- * ...
2605
- * boost::asio::streambuf b;
2606
- * boost::asio::async_read_until(s, b, match_char('a'), handler);
2607
- * @endcode
2608
- *
2609
- * @par Per-Operation Cancellation
2610
- * This asynchronous operation supports cancellation for the following
2611
- * boost::asio::cancellation_type values:
2612
- *
2613
- * @li @c cancellation_type::terminal
2614
- *
2615
- * @li @c cancellation_type::partial
2616
- *
2617
- * if they are also supported by the @c AsyncReadStream type's
2618
- * @c async_read_some operation.
2619
- */
2620
- template <typename AsyncReadStream, typename Allocator, typename MatchCondition,
2621
- BOOST_ASIO_COMPLETION_TOKEN_FOR(void (boost::system::error_code,
2622
- std::size_t)) ReadToken = default_completion_token_t<
2623
- typename AsyncReadStream::executor_type>>
2624
- inline auto async_read_until(AsyncReadStream& s,
2625
- boost::asio::basic_streambuf<Allocator>& b, MatchCondition match_condition,
2626
- ReadToken&& token = default_completion_token_t<
2627
- typename AsyncReadStream::executor_type>(),
2628
- constraint_t<is_match_condition<MatchCondition>::value> = 0)
2629
- -> decltype(
2630
- async_initiate<ReadToken,
2631
- void (boost::system::error_code, std::size_t)>(
2632
- declval<detail::initiate_async_read_until_match_v1<AsyncReadStream>>(),
2633
- token, basic_streambuf_ref<Allocator>(b), match_condition))
2634
- {
2635
- return async_initiate<ReadToken,
2636
- void (boost::system::error_code, std::size_t)>(
2637
- detail::initiate_async_read_until_match_v1<AsyncReadStream>(s),
2638
- token, basic_streambuf_ref<Allocator>(b), match_condition);
2639
- }
2640
-
2641
- #endif // !defined(BOOST_ASIO_NO_IOSTREAM)
2642
- #endif // !defined(BOOST_ASIO_NO_EXTENSIONS)
2643
- #endif // !defined(BOOST_ASIO_NO_DYNAMIC_BUFFER_V1)
2644
-
2645
- /// Start an asynchronous operation to read data into a dynamic buffer sequence
2646
- /// until it contains a specified delimiter.
2647
- /**
2648
- * This function is used to asynchronously read data into the specified dynamic
2649
- * buffer sequence until the dynamic buffer sequence's get area contains the
2650
- * specified delimiter. It is an initiating function for an @ref
2651
- * asynchronous_operation, and always returns immediately. The asynchronous
2652
- * operation will continue until one of the following conditions is true:
2653
- *
2654
- * @li The get area of the dynamic buffer sequence contains the specified
2655
- * delimiter.
2656
- *
2657
- * @li An error occurred.
2658
- *
2659
- * This operation is implemented in terms of zero or more calls to the stream's
2660
- * async_read_some function, and is known as a <em>composed operation</em>. If
2661
- * the dynamic buffer sequence's get area already contains the delimiter, this
2662
- * asynchronous operation completes immediately. The program must ensure that
2663
- * the stream performs no other read operations (such as async_read,
2664
- * async_read_until, the stream's async_read_some function, or any other
2665
- * composed operations that perform reads) until this operation completes.
2666
- *
2667
- * @param s The stream from which the data is to be read. The type must support
2668
- * the AsyncReadStream concept.
2669
- *
2670
- * @param buffers The dynamic buffer sequence into which the data will be read.
2671
- * Although the buffers object may be copied as necessary, ownership of the
2672
- * underlying memory blocks is retained by the caller, which must guarantee
2673
- * that they remain valid until the completion handler is called.
2674
- *
2675
- * @param delim The delimiter character.
2676
- *
2677
- * @param token The @ref completion_token that will be used to produce a
2678
- * completion handler, which will be called when the read completes.
2679
- * Potential completion tokens include @ref use_future, @ref use_awaitable,
2680
- * @ref yield_context, or a function object with the correct completion
2681
- * signature. The function signature of the completion handler must be:
2682
- * @code void handler(
2683
- * // Result of operation.
2684
- * const boost::system::error_code& error,
2685
- *
2686
- * // The number of bytes in the dynamic buffer sequence's
2687
- * // get area up to and including the delimiter.
2688
- * // 0 if an error occurred.
2689
- * std::size_t bytes_transferred
2690
- * ); @endcode
2691
- * Regardless of whether the asynchronous operation completes immediately or
2692
- * not, the completion handler will not be invoked from within this function.
2693
- * On immediate completion, invocation of the handler will be performed in a
2694
- * manner equivalent to using boost::asio::async_immediate().
2695
- *
2696
- * @par Completion Signature
2697
- * @code void(boost::system::error_code, std::size_t) @endcode
2698
- *
2699
- * @note After a successful async_read_until operation, the dynamic buffer
2700
- * sequence may contain additional data beyond the delimiter. An application
2701
- * will typically leave that data in the dynamic buffer sequence for a
2702
- * subsequent async_read_until operation to examine.
2703
- *
2704
- * @par Example
2705
- * To asynchronously read data into a @c std::string until a newline is
2706
- * encountered:
2707
- * @code std::string data;
2708
- * ...
2709
- * void handler(const boost::system::error_code& e, std::size_t size)
2710
- * {
2711
- * if (!e)
2712
- * {
2713
- * std::string line = data.substr(0, n);
2714
- * data.erase(0, n);
2715
- * ...
2716
- * }
2717
- * }
2718
- * ...
2719
- * boost::asio::async_read_until(s, data, '\n', handler); @endcode
2720
- * After the @c async_read_until operation completes successfully, the buffer
2721
- * @c data contains the delimiter:
2722
- * @code { 'a', 'b', ..., 'c', '\n', 'd', 'e', ... } @endcode
2723
- * The call to @c substr then extracts the data up to and including the
2724
- * delimiter, so that the string @c line contains:
2725
- * @code { 'a', 'b', ..., 'c', '\n' } @endcode
2726
- * After the call to @c erase, the remaining data is left in the buffer @c data
2727
- * as follows:
2728
- * @code { 'd', 'e', ... } @endcode
2729
- * This data may be the start of a new line, to be extracted by a subsequent
2730
- * @c async_read_until operation.
2731
- *
2732
- * @par Per-Operation Cancellation
2733
- * This asynchronous operation supports cancellation for the following
2734
- * boost::asio::cancellation_type values:
2735
- *
2736
- * @li @c cancellation_type::terminal
2737
- *
2738
- * @li @c cancellation_type::partial
2739
- *
2740
- * if they are also supported by the @c AsyncReadStream type's
2741
- * @c async_read_some operation.
2742
- */
2743
- template <typename AsyncReadStream, typename DynamicBuffer_v2,
2744
- BOOST_ASIO_COMPLETION_TOKEN_FOR(void (boost::system::error_code,
2745
- std::size_t)) ReadToken = default_completion_token_t<
2746
- typename AsyncReadStream::executor_type>>
2747
- inline auto async_read_until(AsyncReadStream& s,
2748
- DynamicBuffer_v2 buffers, char delim,
2749
- ReadToken&& token = default_completion_token_t<
2750
- typename AsyncReadStream::executor_type>(),
2751
- constraint_t<
2752
- is_dynamic_buffer_v2<DynamicBuffer_v2>::value
2753
- > = 0)
2754
- -> decltype(
2755
- async_initiate<ReadToken,
2756
- void (boost::system::error_code, std::size_t)>(
2757
- declval<detail::initiate_async_read_until_delim_v2<AsyncReadStream>>(),
2758
- token, static_cast<DynamicBuffer_v2&&>(buffers), delim))
2759
- {
2760
- return async_initiate<ReadToken,
2761
- void (boost::system::error_code, std::size_t)>(
2762
- detail::initiate_async_read_until_delim_v2<AsyncReadStream>(s),
2763
- token, static_cast<DynamicBuffer_v2&&>(buffers), delim);
2764
- }
2765
-
2766
- /// Start an asynchronous operation to read data into a dynamic buffer sequence
2767
- /// until it contains a specified delimiter.
2768
- /**
2769
- * This function is used to asynchronously read data into the specified dynamic
2770
- * buffer sequence until the dynamic buffer sequence's get area contains the
2771
- * specified delimiter. It is an initiating function for an @ref
2772
- * asynchronous_operation, and always returns immediately. The asynchronous
2773
- * operation will continue until one of the following conditions is true:
2774
- *
2775
- * @li The get area of the dynamic buffer sequence contains the specified
2776
- * delimiter.
2777
- *
2778
- * @li An error occurred.
2779
- *
2780
- * This operation is implemented in terms of zero or more calls to the stream's
2781
- * async_read_some function, and is known as a <em>composed operation</em>. If
2782
- * the dynamic buffer sequence's get area already contains the delimiter, this
2783
- * asynchronous operation completes immediately. The program must ensure that
2784
- * the stream performs no other read operations (such as async_read,
2785
- * async_read_until, the stream's async_read_some function, or any other
2786
- * composed operations that perform reads) until this operation completes.
2787
- *
2788
- * @param s The stream from which the data is to be read. The type must support
2789
- * the AsyncReadStream concept.
2790
- *
2791
- * @param buffers The dynamic buffer sequence into which the data will be read.
2792
- * Although the buffers object may be copied as necessary, ownership of the
2793
- * underlying memory blocks is retained by the caller, which must guarantee
2794
- * that they remain valid until the completion handler is called.
2795
- *
2796
- * @param delim The delimiter string.
2797
- *
2798
- * @param token The @ref completion_token that will be used to produce a
2799
- * completion handler, which will be called when the read completes.
2800
- * Potential completion tokens include @ref use_future, @ref use_awaitable,
2801
- * @ref yield_context, or a function object with the correct completion
2802
- * signature. The function signature of the completion handler must be:
2803
- * @code void handler(
2804
- * // Result of operation.
2805
- * const boost::system::error_code& error,
2806
- *
2807
- * // The number of bytes in the dynamic buffer sequence's
2808
- * // get area up to and including the delimiter.
2809
- * std::size_t bytes_transferred
2810
- * ); @endcode
2811
- * Regardless of whether the asynchronous operation completes immediately or
2812
- * not, the completion handler will not be invoked from within this function.
2813
- * On immediate completion, invocation of the handler will be performed in a
2814
- * manner equivalent to using boost::asio::async_immediate().
2815
- *
2816
- * @par Completion Signature
2817
- * @code void(boost::system::error_code, std::size_t) @endcode
2818
- *
2819
- * @note After a successful async_read_until operation, the dynamic buffer
2820
- * sequence may contain additional data beyond the delimiter. An application
2821
- * will typically leave that data in the dynamic buffer sequence for a
2822
- * subsequent async_read_until operation to examine.
2823
- *
2824
- * @par Example
2825
- * To asynchronously read data into a @c std::string until a CR-LF sequence is
2826
- * encountered:
2827
- * @code std::string data;
2828
- * ...
2829
- * void handler(const boost::system::error_code& e, std::size_t size)
2830
- * {
2831
- * if (!e)
2832
- * {
2833
- * std::string line = data.substr(0, n);
2834
- * data.erase(0, n);
2835
- * ...
2836
- * }
2837
- * }
2838
- * ...
2839
- * boost::asio::async_read_until(s, data, "\r\n", handler); @endcode
2840
- * After the @c async_read_until operation completes successfully, the string
2841
- * @c data contains the delimiter:
2842
- * @code { 'a', 'b', ..., 'c', '\r', '\n', 'd', 'e', ... } @endcode
2843
- * The call to @c substr then extracts the data up to and including the
2844
- * delimiter, so that the string @c line contains:
2845
- * @code { 'a', 'b', ..., 'c', '\r', '\n' } @endcode
2846
- * After the call to @c erase, the remaining data is left in the string @c data
2847
- * as follows:
2848
- * @code { 'd', 'e', ... } @endcode
2849
- * This data may be the start of a new line, to be extracted by a subsequent
2850
- * @c async_read_until operation.
2851
- *
2852
- * @par Per-Operation Cancellation
2853
- * This asynchronous operation supports cancellation for the following
2854
- * boost::asio::cancellation_type values:
2855
- *
2856
- * @li @c cancellation_type::terminal
2857
- *
2858
- * @li @c cancellation_type::partial
2859
- *
2860
- * if they are also supported by the @c AsyncReadStream type's
2861
- * @c async_read_some operation.
2862
- */
2863
- template <typename AsyncReadStream, typename DynamicBuffer_v2,
2864
- BOOST_ASIO_COMPLETION_TOKEN_FOR(void (boost::system::error_code,
2865
- std::size_t)) ReadToken = default_completion_token_t<
2866
- typename AsyncReadStream::executor_type>>
2867
- inline auto async_read_until(AsyncReadStream& s, DynamicBuffer_v2 buffers,
2868
- BOOST_ASIO_STRING_VIEW_PARAM delim,
2869
- ReadToken&& token = default_completion_token_t<
2870
- typename AsyncReadStream::executor_type>(),
2871
- constraint_t<
2872
- is_dynamic_buffer_v2<DynamicBuffer_v2>::value
2873
- > = 0)
2874
- -> decltype(
2875
- async_initiate<ReadToken,
2876
- void (boost::system::error_code, std::size_t)>(
2877
- declval<detail::initiate_async_read_until_delim_string_v2<
2878
- AsyncReadStream>>(),
2879
- token, static_cast<DynamicBuffer_v2&&>(buffers),
2880
- static_cast<std::string>(delim)))
2881
- {
2882
- return async_initiate<ReadToken,
2883
- void (boost::system::error_code, std::size_t)>(
2884
- detail::initiate_async_read_until_delim_string_v2<AsyncReadStream>(s),
2885
- token, static_cast<DynamicBuffer_v2&&>(buffers),
2886
- static_cast<std::string>(delim));
2887
- }
2888
-
2889
- #if !defined(BOOST_ASIO_NO_EXTENSIONS)
2890
- #if defined(BOOST_ASIO_HAS_BOOST_REGEX) \
2891
- || defined(GENERATING_DOCUMENTATION)
2892
-
2893
- /// Start an asynchronous operation to read data into a dynamic buffer sequence
2894
- /// until some part of its data matches a regular expression.
2895
- /**
2896
- * This function is used to asynchronously read data into the specified dynamic
2897
- * buffer sequence until the dynamic buffer sequence's get area contains some
2898
- * data that matches a regular expression. It is an initiating function for an
2899
- * @ref asynchronous_operation, and always returns immediately. The
2900
- * asynchronous operation will continue until one of the following conditions
2901
- * is true:
2902
- *
2903
- * @li A substring of the dynamic buffer sequence's get area matches the regular
2904
- * expression.
2905
- *
2906
- * @li An error occurred.
2907
- *
2908
- * This operation is implemented in terms of zero or more calls to the stream's
2909
- * async_read_some function, and is known as a <em>composed operation</em>. If
2910
- * the dynamic buffer sequence's get area already contains data that matches
2911
- * the regular expression, this asynchronous operation completes immediately.
2912
- * The program must ensure that the stream performs no other read operations
2913
- * (such as async_read, async_read_until, the stream's async_read_some
2914
- * function, or any other composed operations that perform reads) until this
2915
- * operation completes.
2916
- *
2917
- * @param s The stream from which the data is to be read. The type must support
2918
- * the AsyncReadStream concept.
2919
- *
2920
- * @param buffers The dynamic buffer sequence into which the data will be read.
2921
- * Although the buffers object may be copied as necessary, ownership of the
2922
- * underlying memory blocks is retained by the caller, which must guarantee
2923
- * that they remain valid until the completion handler is called.
2924
- *
2925
- * @param expr The regular expression.
2926
- *
2927
- * @param token The @ref completion_token that will be used to produce a
2928
- * completion handler, which will be called when the read completes.
2929
- * Potential completion tokens include @ref use_future, @ref use_awaitable,
2930
- * @ref yield_context, or a function object with the correct completion
2931
- * signature. The function signature of the completion handler must be:
2932
- * @code void handler(
2933
- * // Result of operation.
2934
- * const boost::system::error_code& error,
2935
- *
2936
- * // The number of bytes in the dynamic buffer
2937
- * // sequence's get area up to and including the
2938
- * // substring that matches the regular expression.
2939
- * // 0 if an error occurred.
2940
- * std::size_t bytes_transferred
2941
- * ); @endcode
2942
- * Regardless of whether the asynchronous operation completes immediately or
2943
- * not, the completion handler will not be invoked from within this function.
2944
- * On immediate completion, invocation of the handler will be performed in a
2945
- * manner equivalent to using boost::asio::async_immediate().
2946
- *
2947
- * @par Completion Signature
2948
- * @code void(boost::system::error_code, std::size_t) @endcode
2949
- *
2950
- * @note After a successful async_read_until operation, the dynamic buffer
2951
- * sequence may contain additional data beyond that which matched the regular
2952
- * expression. An application will typically leave that data in the dynamic
2953
- * buffer sequence for a subsequent async_read_until operation to examine.
2954
- *
2955
- * @par Example
2956
- * To asynchronously read data into a @c std::string until a CR-LF sequence is
2957
- * encountered:
2958
- * @code std::string data;
2959
- * ...
2960
- * void handler(const boost::system::error_code& e, std::size_t size)
2961
- * {
2962
- * if (!e)
2963
- * {
2964
- * std::string line = data.substr(0, n);
2965
- * data.erase(0, n);
2966
- * ...
2967
- * }
2968
- * }
2969
- * ...
2970
- * boost::asio::async_read_until(s, data,
2971
- * boost::regex("\r\n"), handler); @endcode
2972
- * After the @c async_read_until operation completes successfully, the string
2973
- * @c data contains the data which matched the regular expression:
2974
- * @code { 'a', 'b', ..., 'c', '\r', '\n', 'd', 'e', ... } @endcode
2975
- * The call to @c substr then extracts the data up to and including the match,
2976
- * so that the string @c line contains:
2977
- * @code { 'a', 'b', ..., 'c', '\r', '\n' } @endcode
2978
- * After the call to @c erase, the remaining data is left in the string @c data
2979
- * as follows:
2980
- * @code { 'd', 'e', ... } @endcode
2981
- * This data may be the start of a new line, to be extracted by a subsequent
2982
- * @c async_read_until operation.
2983
- *
2984
- * @par Per-Operation Cancellation
2985
- * This asynchronous operation supports cancellation for the following
2986
- * boost::asio::cancellation_type values:
2987
- *
2988
- * @li @c cancellation_type::terminal
2989
- *
2990
- * @li @c cancellation_type::partial
2991
- *
2992
- * if they are also supported by the @c AsyncReadStream type's
2993
- * @c async_read_some operation.
2994
- */
2995
- template <typename AsyncReadStream, typename DynamicBuffer_v2, typename Traits,
2996
- BOOST_ASIO_COMPLETION_TOKEN_FOR(void (boost::system::error_code,
2997
- std::size_t)) ReadToken = default_completion_token_t<
2998
- typename AsyncReadStream::executor_type>>
2999
- inline auto async_read_until(AsyncReadStream& s, DynamicBuffer_v2 buffers,
3000
- const boost::basic_regex<char, Traits>& expr,
3001
- ReadToken&& token = default_completion_token_t<
3002
- typename AsyncReadStream::executor_type>(),
3003
- constraint_t<
3004
- is_dynamic_buffer_v2<DynamicBuffer_v2>::value
3005
- > = 0)
3006
- -> decltype(
3007
- async_initiate<ReadToken,
3008
- void (boost::system::error_code, std::size_t)>(
3009
- declval<detail::initiate_async_read_until_expr_v2<AsyncReadStream>>(),
3010
- token, static_cast<DynamicBuffer_v2&&>(buffers), expr))
3011
- {
3012
- return async_initiate<ReadToken,
3013
- void (boost::system::error_code, std::size_t)>(
3014
- detail::initiate_async_read_until_expr_v2<AsyncReadStream>(s),
3015
- token, static_cast<DynamicBuffer_v2&&>(buffers), expr);
3016
- }
3017
-
3018
- #endif // defined(BOOST_ASIO_HAS_BOOST_REGEX)
3019
- // || defined(GENERATING_DOCUMENTATION)
3020
-
3021
- /// Start an asynchronous operation to read data into a dynamic buffer sequence
3022
- /// until a function object indicates a match.
3023
- /**
3024
- * This function is used to asynchronously read data into the specified dynamic
3025
- * buffer sequence until a user-defined match condition function object, when
3026
- * applied to the data contained in the dynamic buffer sequence, indicates a
3027
- * successful match. It is an initiating function for an @ref
3028
- * asynchronous_operation, and always returns immediately. The asynchronous
3029
- * operation will continue until one of the following conditions is true:
3030
- *
3031
- * @li The match condition function object returns a std::pair where the second
3032
- * element evaluates to true.
3033
- *
3034
- * @li An error occurred.
3035
- *
3036
- * This operation is implemented in terms of zero or more calls to the stream's
3037
- * async_read_some function, and is known as a <em>composed operation</em>. If
3038
- * the match condition function object already indicates a match, this
3039
- * asynchronous operation completes immediately. The program must ensure that
3040
- * the stream performs no other read operations (such as async_read,
3041
- * async_read_until, the stream's async_read_some function, or any other
3042
- * composed operations that perform reads) until this operation completes.
3043
- *
3044
- * @param s The stream from which the data is to be read. The type must support
3045
- * the AsyncReadStream concept.
3046
- *
3047
- * @param buffers The dynamic buffer sequence into which the data will be read.
3048
- * Although the buffers object may be copied as necessary, ownership of the
3049
- * underlying memory blocks is retained by the caller, which must guarantee
3050
- * that they remain valid until the completion handler is called.
3051
- *
3052
- * @param match_condition The function object to be called to determine whether
3053
- * a match exists. The signature of the function object must be:
3054
- * @code pair<iterator, bool> match_condition(iterator begin, iterator end);
3055
- * @endcode
3056
- * where @c iterator represents the type:
3057
- * @code buffers_iterator<typename DynamicBuffer_v2::const_buffers_type>
3058
- * @endcode
3059
- * The iterator parameters @c begin and @c end define the range of bytes to be
3060
- * scanned to determine whether there is a match. The @c first member of the
3061
- * return value is an iterator marking one-past-the-end of the bytes that have
3062
- * been consumed by the match function. This iterator is used to calculate the
3063
- * @c begin parameter for any subsequent invocation of the match condition. The
3064
- * @c second member of the return value is true if a match has been found, false
3065
- * otherwise.
3066
- *
3067
- * @param token The @ref completion_token that will be used to produce a
3068
- * completion handler, which will be called when the read completes.
3069
- * Potential completion tokens include @ref use_future, @ref use_awaitable,
3070
- * @ref yield_context, or a function object with the correct completion
3071
- * signature. The function signature of the completion handler must be:
3072
- * @code void handler(
3073
- * // Result of operation.
3074
- * const boost::system::error_code& error,
3075
- *
3076
- * // The number of bytes in the dynamic buffer sequence's
3077
- * // get area that have been fully consumed by the match
3078
- * // function. O if an error occurred.
3079
- * std::size_t bytes_transferred
3080
- * ); @endcode
3081
- * Regardless of whether the asynchronous operation completes immediately or
3082
- * not, the completion handler will not be invoked from within this function.
3083
- * On immediate completion, invocation of the handler will be performed in a
3084
- * manner equivalent to using boost::asio::async_immediate().
3085
- *
3086
- * @note After a successful async_read_until operation, the dynamic buffer
3087
- * sequence may contain additional data beyond that which matched the function
3088
- * object. An application will typically leave that data in the dynamic buffer
3089
- * sequence for a subsequent async_read_until operation to examine.
3090
- *
3091
- * @par Completion Signature
3092
- * @code void(boost::system::error_code, std::size_t) @endcode
3093
- *
3094
- * @note The default implementation of the @c is_match_condition type trait
3095
- * evaluates to true for function pointers and function objects with a
3096
- * @c result_type typedef. It must be specialised for other user-defined
3097
- * function objects.
3098
- *
3099
- * @par Examples
3100
- * To asynchronously read data into a @c std::string until whitespace is
3101
- * encountered:
3102
- * @code typedef boost::asio::buffers_iterator<
3103
- * boost::asio::const_buffers_1> iterator;
3104
- *
3105
- * std::pair<iterator, bool>
3106
- * match_whitespace(iterator begin, iterator end)
3107
- * {
3108
- * iterator i = begin;
3109
- * while (i != end)
3110
- * if (std::isspace(*i++))
3111
- * return std::make_pair(i, true);
3112
- * return std::make_pair(i, false);
3113
- * }
3114
- * ...
3115
- * void handler(const boost::system::error_code& e, std::size_t size);
3116
- * ...
3117
- * std::string data;
3118
- * boost::asio::async_read_until(s, data, match_whitespace, handler);
3119
- * @endcode
3120
- *
3121
- * To asynchronously read data into a @c std::string until a matching character
3122
- * is found:
3123
- * @code class match_char
3124
- * {
3125
- * public:
3126
- * explicit match_char(char c) : c_(c) {}
3127
- *
3128
- * template <typename Iterator>
3129
- * std::pair<Iterator, bool> operator()(
3130
- * Iterator begin, Iterator end) const
3131
- * {
3132
- * Iterator i = begin;
3133
- * while (i != end)
3134
- * if (c_ == *i++)
3135
- * return std::make_pair(i, true);
3136
- * return std::make_pair(i, false);
3137
- * }
3138
- *
3139
- * private:
3140
- * char c_;
3141
- * };
3142
- *
3143
- * namespace asio {
3144
- * template <> struct is_match_condition<match_char>
3145
- * : public boost::true_type {};
3146
- * } // namespace asio
3147
- * ...
3148
- * void handler(const boost::system::error_code& e, std::size_t size);
3149
- * ...
3150
- * std::string data;
3151
- * boost::asio::async_read_until(s, data, match_char('a'), handler);
3152
- * @endcode
3153
- *
3154
- * @par Per-Operation Cancellation
3155
- * This asynchronous operation supports cancellation for the following
3156
- * boost::asio::cancellation_type values:
3157
- *
3158
- * @li @c cancellation_type::terminal
3159
- *
3160
- * @li @c cancellation_type::partial
3161
- *
3162
- * if they are also supported by the @c AsyncReadStream type's
3163
- * @c async_read_some operation.
3164
- */
3165
- template <typename AsyncReadStream,
3166
- typename DynamicBuffer_v2, typename MatchCondition,
3167
- BOOST_ASIO_COMPLETION_TOKEN_FOR(void (boost::system::error_code,
3168
- std::size_t)) ReadToken = default_completion_token_t<
3169
- typename AsyncReadStream::executor_type>>
3170
- inline auto async_read_until(AsyncReadStream& s,
3171
- DynamicBuffer_v2 buffers, MatchCondition match_condition,
3172
- ReadToken&& token = default_completion_token_t<
3173
- typename AsyncReadStream::executor_type>(),
3174
- constraint_t<
3175
- is_match_condition<MatchCondition>::value
3176
- > = 0,
3177
- constraint_t<
3178
- is_dynamic_buffer_v2<DynamicBuffer_v2>::value
3179
- > = 0)
3180
- -> decltype(
3181
- async_initiate<ReadToken,
3182
- void (boost::system::error_code, std::size_t)>(
3183
- declval<detail::initiate_async_read_until_match_v2<AsyncReadStream>>(),
3184
- token, static_cast<DynamicBuffer_v2&&>(buffers), match_condition))
3185
- {
3186
- return async_initiate<ReadToken,
3187
- void (boost::system::error_code, std::size_t)>(
3188
- detail::initiate_async_read_until_match_v2<AsyncReadStream>(s),
3189
- token, static_cast<DynamicBuffer_v2&&>(buffers),
3190
- match_condition);
3191
- }
3192
-
3193
- #endif // !defined(BOOST_ASIO_NO_EXTENSIONS)
3194
-
3195
- /*@}*/
3196
-
3197
- } // namespace asio
3198
- } // namespace boost
3199
-
3200
- #include <boost/asio/detail/pop_options.hpp>
3201
-
3202
- #include <boost/asio/impl/read_until.hpp>
3203
-
3204
- #endif // BOOST_ASIO_READ_UNTIL_HPP