├── .gitignore ├── asio ├── include │ ├── .gitignore │ └── asio │ │ ├── unyield.hpp │ │ ├── yield.hpp │ │ ├── ts │ │ ├── io_context.hpp │ │ ├── buffer.hpp │ │ ├── net.hpp │ │ ├── timer.hpp │ │ └── socket.hpp │ │ ├── detail │ │ ├── limits.hpp │ │ ├── cstddef.hpp │ │ ├── array.hpp │ │ ├── exception.hpp │ │ ├── functional.hpp │ │ ├── date_time_fwd.hpp │ │ ├── regex_fwd.hpp │ │ ├── array_fwd.hpp │ │ ├── dependent_type.hpp │ │ ├── win_iocp_thread_info.hpp │ │ ├── impl │ │ │ └── thread_context.ipp │ │ └── assert.hpp │ │ ├── buffered_stream_fwd.hpp │ │ ├── version.hpp │ │ ├── buffered_read_stream_fwd.hpp │ │ ├── buffered_write_stream_fwd.hpp │ │ ├── signal_set.hpp │ │ ├── ssl.hpp │ │ ├── system_error.hpp │ │ ├── ssl │ │ └── impl │ │ │ └── src.hpp │ │ ├── static_thread_pool.hpp │ │ ├── streambuf.hpp │ │ ├── impl │ │ └── system_context.hpp │ │ ├── experimental │ │ └── co_composed.hpp │ │ ├── associator.hpp │ │ ├── stream_file.hpp │ │ ├── basic_streambuf_fwd.hpp │ │ ├── readable_pipe.hpp │ │ └── writable_pipe.hpp ├── src │ ├── doc │ │ ├── noncopyable_dox.txt │ │ ├── project-root.jam │ │ ├── .gitignore │ │ ├── asio.png │ │ ├── std_exception_dox.txt │ │ ├── overview │ │ │ ├── proactor.png │ │ │ ├── sync_op.png │ │ │ ├── async_op1.png │ │ │ ├── async_op2.png │ │ │ └── model │ │ │ │ ├── async_op_model.png │ │ │ │ ├── async_op_phases.png │ │ │ │ ├── async_agent_chain.png │ │ │ │ ├── async_agent_model.png │ │ │ │ ├── higher_level_model.png │ │ │ │ ├── async_op_init_complete.png │ │ │ │ ├── async_op_trivial_chain.png │ │ │ │ ├── completion_token_model.png │ │ │ │ ├── async_child_agent_chain.png │ │ │ │ └── completion_token_transform.png │ │ ├── boost_bind_dox.txt │ │ ├── requirements_dox.txt │ │ ├── model_dox.txt │ │ ├── index.xml │ │ ├── requirements │ │ │ ├── DynamicBuffer.qbk │ │ │ ├── WaitHandler.qbk │ │ │ ├── AcceptHandler.qbk │ │ │ ├── ConnectHandler.qbk │ │ │ ├── ShutdownHandler.qbk │ │ │ ├── HandshakeHandler.qbk │ │ │ ├── ReadHandler.qbk │ │ │ ├── SignalHandler.qbk │ │ │ ├── WriteHandler.qbk │ │ │ ├── BufferedHandshakeHandler.qbk │ │ │ ├── MoveAcceptHandler.qbk │ │ │ ├── IteratorConnectHandler.qbk │ │ │ ├── RangeConnectHandler.qbk │ │ │ ├── Handler.qbk │ │ │ ├── ResolveHandler.qbk │ │ │ ├── ProtoAllocator.qbk │ │ │ ├── AcceptableProtocol.qbk │ │ │ └── IoControlCommand.qbk │ │ ├── doxy2qbk.pl │ │ └── makepdf.pl │ ├── examples │ │ ├── cpp20 │ │ │ ├── invocation │ │ │ │ └── .gitignore │ │ │ ├── channels │ │ │ │ └── .gitignore │ │ │ ├── type_erasure │ │ │ │ ├── .gitignore │ │ │ │ ├── sleep.cpp │ │ │ │ └── stdin_line_reader.hpp │ │ │ ├── operations │ │ │ │ └── .gitignore │ │ │ └── coroutines │ │ │ │ └── .gitignore │ │ ├── cpp11 │ │ │ ├── handler_tracking │ │ │ │ └── .gitignore │ │ │ ├── files │ │ │ │ └── .gitignore │ │ │ ├── executors │ │ │ │ └── .gitignore │ │ │ ├── icmp │ │ │ │ └── .gitignore │ │ │ ├── timers │ │ │ │ └── .gitignore │ │ │ ├── windows │ │ │ │ └── .gitignore │ │ │ ├── allocation │ │ │ │ └── .gitignore │ │ │ ├── http │ │ │ │ ├── client │ │ │ │ │ └── .gitignore │ │ │ │ ├── server │ │ │ │ │ ├── .gitignore │ │ │ │ │ ├── header.hpp │ │ │ │ │ ├── mime_types.hpp │ │ │ │ │ ├── request.hpp │ │ │ │ │ └── connection_manager.cpp │ │ │ │ ├── server2 │ │ │ │ │ ├── .gitignore │ │ │ │ │ ├── header.hpp │ │ │ │ │ ├── mime_types.hpp │ │ │ │ │ └── request.hpp │ │ │ │ ├── server3 │ │ │ │ │ ├── .gitignore │ │ │ │ │ ├── header.hpp │ │ │ │ │ ├── mime_types.hpp │ │ │ │ │ └── request.hpp │ │ │ │ └── server4 │ │ │ │ │ ├── .gitignore │ │ │ │ │ ├── header.hpp │ │ │ │ │ ├── mime_types.hpp │ │ │ │ │ └── request.hpp │ │ │ ├── socks4 │ │ │ │ └── .gitignore │ │ │ ├── tutorial │ │ │ │ ├── timer1 │ │ │ │ │ ├── .gitignore │ │ │ │ │ └── timer.cpp │ │ │ │ ├── timer2 │ │ │ │ │ ├── .gitignore │ │ │ │ │ └── timer.cpp │ │ │ │ ├── timer3 │ │ │ │ │ └── .gitignore │ │ │ │ ├── timer4 │ │ │ │ │ └── .gitignore │ │ │ │ ├── timer5 │ │ │ │ │ └── .gitignore │ │ │ │ ├── daytime1 │ │ │ │ │ └── .gitignore │ │ │ │ ├── daytime2 │ │ │ │ │ └── .gitignore │ │ │ │ ├── daytime3 │ │ │ │ │ └── .gitignore │ │ │ │ ├── daytime4 │ │ │ │ │ └── .gitignore │ │ │ │ ├── daytime5 │ │ │ │ │ └── .gitignore │ │ │ │ ├── daytime6 │ │ │ │ │ └── .gitignore │ │ │ │ └── daytime7 │ │ │ │ │ └── .gitignore │ │ │ ├── buffers │ │ │ │ └── .gitignore │ │ │ ├── deferred │ │ │ │ ├── .gitignore │ │ │ │ └── deferred_1.cpp │ │ │ ├── operations │ │ │ │ └── .gitignore │ │ │ ├── ssl │ │ │ │ ├── .gitignore │ │ │ │ └── README │ │ │ ├── type_erasure │ │ │ │ ├── .gitignore │ │ │ │ ├── sleep.cpp │ │ │ │ └── stdin_line_reader.hpp │ │ │ ├── chat │ │ │ │ └── .gitignore │ │ │ ├── echo │ │ │ │ └── .gitignore │ │ │ ├── futures │ │ │ │ └── .gitignore │ │ │ ├── invocation │ │ │ │ └── .gitignore │ │ │ ├── multicast │ │ │ │ └── .gitignore │ │ │ ├── nonblocking │ │ │ │ └── .gitignore │ │ │ ├── porthopper │ │ │ │ └── .gitignore │ │ │ ├── services │ │ │ │ ├── .gitignore │ │ │ │ ├── logger_service.cpp │ │ │ │ └── logger.hpp │ │ │ ├── timeouts │ │ │ │ └── .gitignore │ │ │ ├── iostreams │ │ │ │ └── .gitignore │ │ │ ├── serialization │ │ │ │ └── .gitignore │ │ │ ├── fork │ │ │ │ └── .gitignore │ │ │ ├── spawn │ │ │ │ └── .gitignore │ │ │ ├── local │ │ │ │ └── .gitignore │ │ │ └── parallel_group │ │ │ │ └── .gitignore │ │ ├── cpp14 │ │ │ ├── executors │ │ │ │ └── .gitignore │ │ │ ├── deferred │ │ │ │ ├── .gitignore │ │ │ │ └── deferred_1.cpp │ │ │ ├── echo │ │ │ │ └── .gitignore │ │ │ ├── iostreams │ │ │ │ └── .gitignore │ │ │ ├── operations │ │ │ │ └── .gitignore │ │ │ └── parallel_group │ │ │ │ └── .gitignore │ │ └── cpp17 │ │ │ └── coroutines_ts │ │ │ └── .gitignore │ ├── .gitignore │ ├── tests │ │ ├── .gitignore │ │ ├── latency │ │ │ └── .gitignore │ │ ├── performance │ │ │ └── .gitignore │ │ ├── properties │ │ │ ├── .gitignore │ │ │ ├── cpp03 │ │ │ │ ├── can_query_not_applicable_unsupported.cpp │ │ │ │ ├── can_require_concept_not_applicable_unsupported.cpp │ │ │ │ ├── can_query_unsupported.cpp │ │ │ │ ├── can_require_concept_unsupported.cpp │ │ │ │ ├── can_query_not_applicable_static.cpp │ │ │ │ ├── can_query_not_applicable_member.cpp │ │ │ │ └── can_query_not_applicable_free.cpp │ │ │ ├── cpp14 │ │ │ │ ├── can_query_not_applicable_unsupported.cpp │ │ │ │ ├── can_query_not_applicable_member.cpp │ │ │ │ ├── can_query_unsupported.cpp │ │ │ │ ├── can_query_not_applicable_free.cpp │ │ │ │ ├── can_query_not_applicable_static.cpp │ │ │ │ ├── can_query_member.cpp │ │ │ │ ├── can_query_free.cpp │ │ │ │ ├── can_query_static.cpp │ │ │ │ ├── can_require_concept_not_applicable_unsupported.cpp │ │ │ │ ├── can_require_concept_not_applicable_member.cpp │ │ │ │ ├── can_require_concept_not_applicable_static.cpp │ │ │ │ ├── can_require_concept_unsupported.cpp │ │ │ │ ├── can_require_concept_not_applicable_free.cpp │ │ │ │ ├── can_require_concept_member.cpp │ │ │ │ ├── can_require_concept_static.cpp │ │ │ │ └── can_require_concept_free.cpp │ │ │ └── cpp11 │ │ │ │ ├── can_query_not_applicable_unsupported.cpp │ │ │ │ ├── can_query_not_applicable_member.cpp │ │ │ │ ├── can_query_not_applicable_free.cpp │ │ │ │ ├── can_require_concept_not_applicable_unsupported.cpp │ │ │ │ ├── can_query_unsupported.cpp │ │ │ │ ├── can_query_member.cpp │ │ │ │ ├── can_query_free.cpp │ │ │ │ ├── can_require_concept_unsupported.cpp │ │ │ │ ├── can_require_concept_not_applicable_member.cpp │ │ │ │ └── can_require_concept_not_applicable_free.cpp │ │ └── unit │ │ │ ├── ssl │ │ │ ├── .gitignore │ │ │ ├── error.cpp │ │ │ ├── context.cpp │ │ │ ├── stream_base.cpp │ │ │ ├── context_base.cpp │ │ │ └── host_name_verification.cpp │ │ │ ├── ts │ │ │ ├── .gitignore │ │ │ ├── net.cpp │ │ │ ├── timer.cpp │ │ │ ├── buffer.cpp │ │ │ ├── socket.cpp │ │ │ ├── executor.cpp │ │ │ ├── internet.cpp │ │ │ ├── io_context.cpp │ │ │ └── netfwd.cpp │ │ │ ├── generic │ │ │ ├── .gitignore │ │ │ └── basic_endpoint.cpp │ │ │ ├── local │ │ │ ├── .gitignore │ │ │ └── basic_endpoint.cpp │ │ │ ├── experimental │ │ │ ├── coro │ │ │ │ └── .gitignore │ │ │ ├── .gitignore │ │ │ ├── co_composed.cpp │ │ │ ├── basic_channel.cpp │ │ │ ├── channel_traits.cpp │ │ │ ├── parallel_group.cpp │ │ │ └── basic_concurrent_channel.cpp │ │ │ ├── posix │ │ │ ├── .gitignore │ │ │ ├── descriptor.cpp │ │ │ ├── descriptor_base.cpp │ │ │ ├── basic_descriptor.cpp │ │ │ └── basic_stream_descriptor.cpp │ │ │ ├── execution │ │ │ ├── .gitignore │ │ │ └── invocable_archetype.cpp │ │ │ ├── windows │ │ │ ├── .gitignore │ │ │ ├── basic_object_handle.cpp │ │ │ ├── basic_stream_handle.cpp │ │ │ ├── basic_overlapped_handle.cpp │ │ │ ├── overlapped_handle.cpp │ │ │ └── basic_random_access_handle.cpp │ │ │ ├── ip │ │ │ ├── .gitignore │ │ │ ├── basic_endpoint.cpp │ │ │ ├── basic_resolver.cpp │ │ │ ├── resolver_query_base.cpp │ │ │ ├── basic_resolver_entry.cpp │ │ │ ├── basic_resolver_query.cpp │ │ │ ├── basic_resolver_iterator.cpp │ │ │ ├── address_v4_range.cpp │ │ │ ├── address_v6_range.cpp │ │ │ ├── address_v4_iterator.cpp │ │ │ └── address_v6_iterator.cpp │ │ │ ├── post.cpp │ │ │ ├── defer.cpp │ │ │ ├── thread.cpp │ │ │ ├── detached.cpp │ │ │ ├── dispatch.cpp │ │ │ ├── executor.cpp │ │ │ ├── file_base.cpp │ │ │ ├── awaitable.cpp │ │ │ ├── immediate.cpp │ │ │ ├── this_coro.cpp │ │ │ ├── associator.cpp │ │ │ ├── basic_file.cpp │ │ │ ├── deferred.cpp │ │ │ ├── time_traits.cpp │ │ │ ├── wait_traits.cpp │ │ │ ├── async_result.cpp │ │ │ ├── basic_socket.cpp │ │ │ ├── placeholders.cpp │ │ │ ├── packaged_task.cpp │ │ │ ├── use_awaitable.cpp │ │ │ ├── uses_executor.cpp │ │ │ ├── basic_streambuf.cpp │ │ │ ├── basic_raw_socket.cpp │ │ │ ├── basic_signal_set.cpp │ │ │ ├── basic_stream_file.cpp │ │ │ ├── cancellation_type.cpp │ │ │ ├── execution_context.cpp │ │ │ ├── cancellation_state.cpp │ │ │ ├── associated_executor.cpp │ │ │ ├── basic_readable_pipe.cpp │ │ │ ├── basic_stream_socket.cpp │ │ │ ├── basic_writable_pipe.cpp │ │ │ ├── buffer_registration.cpp │ │ │ ├── cancellation_signal.cpp │ │ │ ├── executor_work_guard.cpp │ │ │ ├── associated_allocator.cpp │ │ │ ├── basic_deadline_timer.cpp │ │ │ ├── basic_waitable_timer.cpp │ │ │ ├── completion_condition.cpp │ │ │ ├── basic_datagram_socket.cpp │ │ │ ├── basic_socket_acceptor.cpp │ │ │ ├── basic_seq_packet_socket.cpp │ │ │ ├── archetypes │ │ │ └── io_control_command.hpp │ │ │ ├── basic_random_access_file.cpp │ │ │ ├── associated_cancellation_slot.cpp │ │ │ ├── associated_immediate_executor.cpp │ │ │ ├── basic_serial_port.cpp │ │ │ ├── steady_timer.cpp │ │ │ ├── system_context.cpp │ │ │ ├── signal_set_base.cpp │ │ │ ├── static_thread_pool.cpp │ │ │ └── high_resolution_timer.cpp │ ├── asio.cpp │ ├── asio_ssl.cpp │ └── Makefile.am ├── README ├── INSTALL ├── COPYING ├── .gitignore ├── asio.pc.in └── Makefile.am └── .cirrus.yml /.gitignore: -------------------------------------------------------------------------------- 1 | /*.cpp 2 | /*.hpp 3 | /boost 4 | -------------------------------------------------------------------------------- /asio/include/.gitignore: -------------------------------------------------------------------------------- 1 | Makefile 2 | Makefile.in 3 | -------------------------------------------------------------------------------- /asio/src/doc/noncopyable_dox.txt: -------------------------------------------------------------------------------- 1 | /** 2 | \class noncopyable 3 | */ 4 | -------------------------------------------------------------------------------- /asio/src/doc/project-root.jam: -------------------------------------------------------------------------------- 1 | # This file intentionally left blank. 2 | -------------------------------------------------------------------------------- /asio/src/examples/cpp20/invocation/.gitignore: -------------------------------------------------------------------------------- 1 | completion_executor 2 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/handler_tracking/.gitignore: -------------------------------------------------------------------------------- 1 | async_tcp_echo_server 2 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/files/.gitignore: -------------------------------------------------------------------------------- 1 | async_file_copy 2 | blocking_file_copy 3 | -------------------------------------------------------------------------------- /asio/src/doc/.gitignore: -------------------------------------------------------------------------------- 1 | bin 2 | html 3 | reference.tags 4 | asio.docbook 5 | *.pdf 6 | -------------------------------------------------------------------------------- /asio/src/examples/cpp20/channels/.gitignore: -------------------------------------------------------------------------------- 1 | mutual_exclusion_[0-9] 2 | throttling_proxy 3 | -------------------------------------------------------------------------------- /asio/src/doc/asio.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SinghRajenM/asio/master/asio/src/doc/asio.png -------------------------------------------------------------------------------- /asio/src/doc/std_exception_dox.txt: -------------------------------------------------------------------------------- 1 | /** 2 | \namespace std 3 | */ 4 | 5 | /** 6 | \class std::exception 7 | */ 8 | -------------------------------------------------------------------------------- /asio/src/doc/overview/proactor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SinghRajenM/asio/master/asio/src/doc/overview/proactor.png -------------------------------------------------------------------------------- /asio/src/doc/overview/sync_op.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SinghRajenM/asio/master/asio/src/doc/overview/sync_op.png -------------------------------------------------------------------------------- /asio/src/doc/overview/async_op1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SinghRajenM/asio/master/asio/src/doc/overview/async_op1.png -------------------------------------------------------------------------------- /asio/src/doc/overview/async_op2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SinghRajenM/asio/master/asio/src/doc/overview/async_op2.png -------------------------------------------------------------------------------- /asio/src/examples/cpp11/executors/.gitignore: -------------------------------------------------------------------------------- 1 | actor 2 | bank_account_[0-9] 3 | fork_join 4 | pipeline 5 | priority_scheduler 6 | -------------------------------------------------------------------------------- /asio/README: -------------------------------------------------------------------------------- 1 | asio version 1.34.2 2 | Released Friday, 11 April 2025. 3 | 4 | See doc/index.html for API documentation and a tutorial. 5 | -------------------------------------------------------------------------------- /asio/src/examples/cpp14/executors/.gitignore: -------------------------------------------------------------------------------- 1 | actor 2 | async_[0-9] 3 | bank_account_[0-9] 4 | fork_join 5 | pipeline 6 | priority_scheduler 7 | -------------------------------------------------------------------------------- /asio/src/doc/overview/model/async_op_model.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SinghRajenM/asio/master/asio/src/doc/overview/model/async_op_model.png -------------------------------------------------------------------------------- /asio/src/doc/overview/model/async_op_phases.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SinghRajenM/asio/master/asio/src/doc/overview/model/async_op_phases.png -------------------------------------------------------------------------------- /asio/src/.gitignore: -------------------------------------------------------------------------------- 1 | Makefile 2 | Makefile.in 3 | .deps 4 | *.a 5 | *.o 6 | *.obj 7 | *.lib 8 | *.pdb 9 | *.log 10 | *.trs 11 | *.dirstamp 12 | -------------------------------------------------------------------------------- /asio/src/doc/overview/model/async_agent_chain.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SinghRajenM/asio/master/asio/src/doc/overview/model/async_agent_chain.png -------------------------------------------------------------------------------- /asio/src/doc/overview/model/async_agent_model.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SinghRajenM/asio/master/asio/src/doc/overview/model/async_agent_model.png -------------------------------------------------------------------------------- /asio/src/doc/overview/model/higher_level_model.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SinghRajenM/asio/master/asio/src/doc/overview/model/higher_level_model.png -------------------------------------------------------------------------------- /asio/src/examples/cpp11/icmp/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | ping 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/tests/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *_test 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | *.winmd 12 | -------------------------------------------------------------------------------- /asio/src/doc/overview/model/async_op_init_complete.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SinghRajenM/asio/master/asio/src/doc/overview/model/async_op_init_complete.png -------------------------------------------------------------------------------- /asio/src/doc/overview/model/async_op_trivial_chain.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SinghRajenM/asio/master/asio/src/doc/overview/model/async_op_trivial_chain.png -------------------------------------------------------------------------------- /asio/src/doc/overview/model/completion_token_model.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SinghRajenM/asio/master/asio/src/doc/overview/model/completion_token_model.png -------------------------------------------------------------------------------- /asio/src/examples/cpp11/timers/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *timer 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/windows/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | server 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/doc/overview/model/async_child_agent_chain.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SinghRajenM/asio/master/asio/src/doc/overview/model/async_child_agent_chain.png -------------------------------------------------------------------------------- /asio/src/examples/cpp11/allocation/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | server 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/client/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *_client 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/socks4/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | sync_client 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/tutorial/timer1/.gitignore: -------------------------------------------------------------------------------- 1 | timer 2 | .deps 3 | .dirstamp 4 | *.o 5 | *.obj 6 | *.exe 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/tutorial/timer2/.gitignore: -------------------------------------------------------------------------------- 1 | timer 2 | .deps 3 | .dirstamp 4 | *.o 5 | *.obj 6 | *.exe 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/tutorial/timer3/.gitignore: -------------------------------------------------------------------------------- 1 | timer 2 | .deps 3 | .dirstamp 4 | *.o 5 | *.obj 6 | *.exe 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/tutorial/timer4/.gitignore: -------------------------------------------------------------------------------- 1 | timer 2 | .deps 3 | .dirstamp 4 | *.o 5 | *.obj 6 | *.exe 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/tutorial/timer5/.gitignore: -------------------------------------------------------------------------------- 1 | timer 2 | .deps 3 | .dirstamp 4 | *.o 5 | *.obj 6 | *.exe 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/tests/latency/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *client 7 | *server 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/tests/performance/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | client 7 | server 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/doc/overview/model/completion_token_transform.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SinghRajenM/asio/master/asio/src/doc/overview/model/completion_token_transform.png -------------------------------------------------------------------------------- /asio/src/examples/cpp11/buffers/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | reference_counted 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/deferred/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | deferred_[0-9] 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/operations/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | composed_[0-9] 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/ssl/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | server 7 | client 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/tutorial/daytime1/.gitignore: -------------------------------------------------------------------------------- 1 | client 2 | .deps 3 | .dirstamp 4 | *.o 5 | *.obj 6 | *.exe 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/tutorial/daytime2/.gitignore: -------------------------------------------------------------------------------- 1 | server 2 | .deps 3 | .dirstamp 4 | *.o 5 | *.obj 6 | *.exe 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/tutorial/daytime3/.gitignore: -------------------------------------------------------------------------------- 1 | server 2 | .deps 3 | .dirstamp 4 | *.o 5 | *.obj 6 | *.exe 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/tutorial/daytime4/.gitignore: -------------------------------------------------------------------------------- 1 | client 2 | .deps 3 | .dirstamp 4 | *.o 5 | *.obj 6 | *.exe 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/tutorial/daytime5/.gitignore: -------------------------------------------------------------------------------- 1 | server 2 | .deps 3 | .dirstamp 4 | *.o 5 | *.obj 6 | *.exe 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/tutorial/daytime6/.gitignore: -------------------------------------------------------------------------------- 1 | server 2 | .deps 3 | .dirstamp 4 | *.o 5 | *.obj 6 | *.exe 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/tutorial/daytime7/.gitignore: -------------------------------------------------------------------------------- 1 | server 2 | .deps 3 | .dirstamp 4 | *.o 5 | *.obj 6 | *.exe 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/type_erasure/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | type_erasure 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp14/deferred/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | deferred_[0-9] 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp20/type_erasure/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | type_erasure 11 | -------------------------------------------------------------------------------- /asio/src/tests/properties/.gitignore: -------------------------------------------------------------------------------- 1 | *_free 2 | *_free_prefer 3 | *_free_require 4 | *_member 5 | *_member_prefer 6 | *_member_require 7 | *_static 8 | *_unsupported 9 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/chat/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *_server 7 | *_client 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/echo/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *_server 7 | *_client 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/futures/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *_server 7 | *_client 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/invocation/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | prioritised_handlers 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/multicast/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | receiver 4 | sender 5 | *.o 6 | *.obj 7 | *.exe 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/nonblocking/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | third_party_lib 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/porthopper/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | client 7 | server 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/services/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *_client 7 | *.ilk 8 | *.manifest 9 | *.pdb 10 | *.tds 11 | log.txt 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/timeouts/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *_client 7 | server 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp14/echo/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *_server 7 | *_client 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *_server 7 | *_client 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server2/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *_server 7 | *_client 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server3/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *_server 7 | *_client 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server4/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *_server 7 | *_client 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/iostreams/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *_client 7 | *_server 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/serialization/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | client 7 | server 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp14/iostreams/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *_client 7 | *_server 8 | *.ilk 9 | *.manifest 10 | *.pdb 11 | *.tds 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/fork/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | daemon 11 | process_per_connection 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/spawn/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | parallel_grep 4 | *.o 5 | *.obj 6 | *.exe 7 | *_server 8 | *_client 9 | *.ilk 10 | *.manifest 11 | *.pdb 12 | *.tds 13 | -------------------------------------------------------------------------------- /asio/INSTALL: -------------------------------------------------------------------------------- 1 | See doc/index.html for information on: 2 | - External dependencies 3 | - Using, building, and configuring Asio 4 | - Supported platforms 5 | - How to build the tests and examples 6 | -------------------------------------------------------------------------------- /asio/src/examples/cpp14/operations/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | c_callback_wrapper 7 | callback_wrapper 8 | composed_[0-9] 9 | *.ilk 10 | *.manifest 11 | *.pdb 12 | *.tds 13 | -------------------------------------------------------------------------------- /asio/src/examples/cpp20/operations/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | c_callback_wrapper 7 | callback_wrapper 8 | composed_[0-9] 9 | *.ilk 10 | *.manifest 11 | *.pdb 12 | *.tds 13 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ssl/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | context 11 | context_base 12 | host_name_verification 13 | stream 14 | stream_base 15 | -------------------------------------------------------------------------------- /asio/src/doc/boost_bind_dox.txt: -------------------------------------------------------------------------------- 1 | /** 2 | \page boost_bind boost::bind 3 | See the Boost: bind.hpp 4 | documentation for more information on how to use boost::bind. 5 | */ 6 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ts/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | buffer 11 | executor 12 | internet 13 | io_context 14 | net 15 | netfwd 16 | socket 17 | timer 18 | -------------------------------------------------------------------------------- /asio/COPYING: -------------------------------------------------------------------------------- 1 | Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 2 | 3 | Distributed under the Boost Software License, Version 1.0. (See accompanying 4 | file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 5 | -------------------------------------------------------------------------------- /asio/src/tests/unit/generic/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | basic_endpoint 11 | datagram_protocol 12 | raw_protocol 13 | seq_packet_protocol 14 | stream_protocol 15 | -------------------------------------------------------------------------------- /asio/src/tests/unit/local/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | basic_endpoint 11 | connect_pair 12 | datagram_protocol 13 | seq_packet_protocol 14 | stream_protocol 15 | -------------------------------------------------------------------------------- /asio/src/tests/unit/experimental/coro/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | allocator 11 | cancel 12 | exception 13 | partial 14 | simple_test 15 | stack_test 16 | use_coro 17 | -------------------------------------------------------------------------------- /asio/src/tests/unit/posix/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | basic_descriptor 11 | basic_stream_descriptor 12 | descriptor 13 | descriptor_base 14 | stream_descriptor 15 | -------------------------------------------------------------------------------- /asio/src/examples/cpp17/coroutines_ts/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | *_server 11 | *_server_with_default 12 | *_server_with_as_single_default 13 | *_server_with_as_tuple_default 14 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/local/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | connect_pair 7 | stream_server 8 | stream_client 9 | iostream_client 10 | fd_passing_stream_server 11 | fd_passing_stream_client 12 | *.ilk 13 | *.manifest 14 | *.pdb 15 | *.tds 16 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/parallel_group/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | parallel_sort 11 | ranged_wait_for_all 12 | wait_for_all 13 | wait_for_one 14 | wait_for_one_error 15 | wait_for_one_success 16 | -------------------------------------------------------------------------------- /asio/src/examples/cpp14/parallel_group/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | parallel_sort 11 | ranged_wait_for_all 12 | wait_for_all 13 | wait_for_one 14 | wait_for_one_error 15 | wait_for_one_success 16 | -------------------------------------------------------------------------------- /asio/src/tests/unit/execution/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | any_executor 11 | blocking 12 | blocking_adaptation 13 | context_as 14 | executor 15 | invocable_archetype 16 | mapping 17 | outstanding_work 18 | prefer_only 19 | relationship 20 | -------------------------------------------------------------------------------- /asio/src/tests/unit/experimental/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | awaitable_operators 11 | basic_channel 12 | basic_concurrent_channel 13 | channel 14 | channel_traits 15 | co_composed 16 | concurrent_channel 17 | parallel_group 18 | promise 19 | -------------------------------------------------------------------------------- /asio/src/examples/cpp20/coroutines/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | *_server 11 | *_server_with_default 12 | *_server_with_deferred 13 | *_server_with_deferred_default 14 | *_server_with_as_single_default 15 | *_server_with_as_tuple_default 16 | timeout 17 | -------------------------------------------------------------------------------- /asio/.gitignore: -------------------------------------------------------------------------------- 1 | Makefile 2 | Makefile.in 3 | aclocal.m4 4 | asio.pc 5 | autom4te.cache 6 | compile 7 | config.guess 8 | config.log 9 | config.status 10 | config.sub 11 | configure 12 | depcomp 13 | install-sh 14 | missing 15 | test-driver 16 | /doc 17 | /lib 18 | /boostified 19 | /tsified 20 | *.gz 21 | *.bz2 22 | *.zip 23 | /*.cpp 24 | /*.hpp 25 | -------------------------------------------------------------------------------- /asio/src/tests/unit/windows/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | basic_object_handle 11 | basic_overlapped_handle 12 | basic_random_access_handle 13 | basic_stream_handle 14 | object_handle 15 | overlapped_handle 16 | overlapped_ptr 17 | random_access_handle 18 | stream_handle 19 | -------------------------------------------------------------------------------- /asio/src/asio.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // asio.cpp 3 | // ~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/impl/src.hpp" 12 | -------------------------------------------------------------------------------- /.cirrus.yml: -------------------------------------------------------------------------------- 1 | freebsd_instance: 2 | image_family: freebsd-14-2 3 | cpu: 1 4 | 5 | env: 6 | CXXFLAGS: -std=c++14 -Wall -Wextra -O2 7 | 8 | task: 9 | install_script: 10 | - pkg install -y autoconf automake pkgconf 11 | build_script: 12 | - cd asio 13 | - ./autogen.sh 14 | - ./configure --with-boost=no 15 | - make 16 | - make check 17 | -------------------------------------------------------------------------------- /asio/src/asio_ssl.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // asio_ssl.cpp 3 | // ~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/ssl/impl/src.hpp" 12 | -------------------------------------------------------------------------------- /asio/src/doc/requirements_dox.txt: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | // 4 | // Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | // 7 | 8 | /** 9 | \page async_result_requirements @c async_result requirements 10 | */ 11 | -------------------------------------------------------------------------------- /asio/asio.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | includedir=@includedir@ 4 | 5 | Name: @PACKAGE_NAME@ 6 | Description: A cross-platform C++ library for network and low-level I/O programming that provides developers with a consistent asynchronous model using a modern C++ approach. 7 | Version: @PACKAGE_VERSION@ 8 | Cflags: -I${includedir} 9 | Lflags: 10 | Requires: 11 | Requires.private: 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/services/logger_service.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // logger_service.cpp 3 | // ~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "logger_service.hpp" 12 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/ssl/README: -------------------------------------------------------------------------------- 1 | The passphrase for both the CA and server private keys is "test". 2 | 3 | 4 | ------------------------------------------------------------------------------- 5 | Copyright (c) 2003-2025 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 | -------------------------------------------------------------------------------- /asio/src/doc/model_dox.txt: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | // 4 | // Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | // 7 | 8 | /** 9 | \page asynchronous_operation asynchronous operation 10 | */ 11 | 12 | /** 13 | \page completion_token completion token 14 | */ 15 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ip/.gitignore: -------------------------------------------------------------------------------- 1 | .deps 2 | .dirstamp 3 | *.o 4 | *.obj 5 | *.exe 6 | *.ilk 7 | *.manifest 8 | *.pdb 9 | *.tds 10 | address 11 | address_v4* 12 | address_v6* 13 | basic_endpoint 14 | basic_resolver 15 | basic_resolver_entry 16 | basic_resolver_iterator 17 | basic_resolver_query 18 | host_name 19 | icmp 20 | multicast 21 | network_v4 22 | network_v6 23 | resolver_query_base 24 | tcp 25 | udp 26 | unicast 27 | v6_only 28 | -------------------------------------------------------------------------------- /asio/include/asio/unyield.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // unyield.hpp 3 | // ~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #ifdef reenter 12 | # undef reenter 13 | #endif 14 | 15 | #ifdef yield 16 | # undef yield 17 | #endif 18 | 19 | #ifdef fork 20 | # undef fork 21 | #endif 22 | -------------------------------------------------------------------------------- /asio/Makefile.am: -------------------------------------------------------------------------------- 1 | AUTOMAKE_OPTIONS = foreign dist-bzip2 dist-zip 2 | 3 | noarch_pkgconfig_DATA = asio.pc 4 | 5 | SUBDIRS = include src 6 | 7 | MAINTAINERCLEANFILES = \ 8 | $(srcdir)/aclocal.m4 \ 9 | $(srcdir)/configure \ 10 | $(srcdir)/config.guess \ 11 | $(srcdir)/config.sub \ 12 | $(srcdir)/depcomp \ 13 | $(srcdir)/install-sh \ 14 | $(srcdir)/missing \ 15 | $(srcdir)/mkinstalldirs \ 16 | $(srcdir)/Makefile.in \ 17 | asio-*.tar.gz 18 | 19 | EXTRA_DIST = \ 20 | LICENSE_1_0.txt \ 21 | doc 22 | -------------------------------------------------------------------------------- /asio/src/doc/index.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 10 | 11 |
12 | 13 |
14 | -------------------------------------------------------------------------------- /asio/src/doc/requirements/DynamicBuffer.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | / Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | / 4 | / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | /] 7 | 8 | [section:DynamicBuffer Dynamic buffer requirements] 9 | 10 | See: 11 | 12 | * [link asio.reference.DynamicBuffer_v1 Dynamic buffer requirements (version 1)] 13 | 14 | * [link asio.reference.DynamicBuffer_v2 Dynamic buffer requirements (version 2)] 15 | 16 | [endsect] 17 | -------------------------------------------------------------------------------- /asio/include/asio/yield.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // yield.hpp 3 | // ~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "coroutine.hpp" 12 | 13 | #ifndef reenter 14 | # define reenter(c) ASIO_CORO_REENTER(c) 15 | #endif 16 | 17 | #ifndef yield 18 | # define yield ASIO_CORO_YIELD 19 | #endif 20 | 21 | #ifndef fork 22 | # define fork ASIO_CORO_FORK 23 | #endif 24 | -------------------------------------------------------------------------------- /asio/src/doc/requirements/WaitHandler.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | / Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | / 4 | / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | /] 7 | 8 | [section:WaitHandler Wait handler requirements] 9 | 10 | A wait handler must meet the requirements for a [link 11 | asio.reference.Handler handler]. A value `h` of a wait handler class 12 | should work correctly in the expression `h(ec)`, where `ec` is an lvalue of 13 | type `const error_code`. 14 | 15 | [endsect] 16 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/tutorial/timer1/timer.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // timer.cpp 3 | // ~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include 12 | #include 13 | 14 | int main() 15 | { 16 | asio::io_context io; 17 | 18 | asio::steady_timer t(io, asio::chrono::seconds(5)); 19 | t.wait(); 20 | 21 | std::cout << "Hello, world!" << std::endl; 22 | 23 | return 0; 24 | } 25 | -------------------------------------------------------------------------------- /asio/src/doc/requirements/AcceptHandler.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | / Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | / 4 | / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | /] 7 | 8 | [section:AcceptHandler Accept handler requirements] 9 | 10 | An accept handler must meet the requirements for a [link 11 | asio.reference.Handler handler]. A value `h` of an accept handler 12 | class should work correctly in the expression `h(ec)`, where `ec` is an lvalue 13 | of type `const error_code`. 14 | 15 | [endsect] 16 | -------------------------------------------------------------------------------- /asio/include/asio/ts/io_context.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // ts/io_context.hpp 3 | // ~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_TS_IO_CONTEXT_HPP 12 | #define ASIO_TS_IO_CONTEXT_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/io_context.hpp" 19 | 20 | #endif // ASIO_TS_IO_CONTEXT_HPP 21 | -------------------------------------------------------------------------------- /asio/src/doc/requirements/ConnectHandler.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | / Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | / 4 | / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | /] 7 | 8 | [section:ConnectHandler Connect handler requirements] 9 | 10 | A connect handler must meet the requirements for a [link 11 | asio.reference.Handler handler]. A value `h` of a connect handler 12 | class should work correctly in the expression `h(ec)`, where `ec` is an lvalue 13 | of type `const error_code`. 14 | 15 | [endsect] 16 | -------------------------------------------------------------------------------- /asio/src/doc/requirements/ShutdownHandler.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | / Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | / 4 | / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | /] 7 | 8 | [section:ShutdownHandler SSL shutdown handler requirements] 9 | 10 | A shutdown handler must meet the requirements for a [link 11 | asio.reference.Handler handler]. A value `h` of a shutdown handler 12 | class should work correctly in the expression `h(ec)`, where `ec` is an lvalue 13 | of type `const error_code`. 14 | 15 | [endsect] 16 | -------------------------------------------------------------------------------- /asio/src/doc/requirements/HandshakeHandler.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | / Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | / 4 | / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | /] 7 | 8 | [section:HandshakeHandler SSL handshake handler requirements] 9 | 10 | A handshake handler must meet the requirements for a [link 11 | asio.reference.Handler handler]. A value `h` of a handshake handler 12 | class should work correctly in the expression `h(ec)`, where `ec` is an lvalue 13 | of type `const error_code`. 14 | 15 | [endsect] 16 | -------------------------------------------------------------------------------- /asio/include/asio/detail/limits.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // detail/limits.hpp 3 | // ~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2011 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 ASIO_DETAIL_LIMITS_HPP 12 | #define ASIO_DETAIL_LIMITS_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/detail/config.hpp" 19 | #include 20 | 21 | #endif // ASIO_DETAIL_LIMITS_HPP 22 | -------------------------------------------------------------------------------- /asio/src/doc/requirements/ReadHandler.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | / Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | / 4 | / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | /] 7 | 8 | [section:ReadHandler Read handler requirements] 9 | 10 | A read handler must meet the requirements for a [link 11 | asio.reference.Handler handler]. A value `h` of a read handler class 12 | should work correctly in the expression `h(ec, s)`, where `ec` is an lvalue of 13 | type `const error_code` and `s` is an lvalue of type `const size_t`. 14 | 15 | [endsect] 16 | -------------------------------------------------------------------------------- /asio/src/doc/requirements/SignalHandler.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | / Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | / 4 | / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | /] 7 | 8 | [section:SignalHandler Signal handler requirements] 9 | 10 | A signal handler must meet the requirements for a [link 11 | asio.reference.Handler handler]. A value `h` of a signal handler class 12 | should work correctly in the expression `h(ec, n)`, where `ec` is an lvalue of 13 | type `const error_code` and `n` is an lvalue of type `const int`. 14 | 15 | [endsect] 16 | -------------------------------------------------------------------------------- /asio/src/doc/requirements/WriteHandler.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | / Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | / 4 | / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | /] 7 | 8 | [section:WriteHandler Write handler requirements] 9 | 10 | A write handler must meet the requirements for a [link 11 | asio.reference.Handler handler]. A value `h` of a write handler class 12 | should work correctly in the expression `h(ec, s)`, where `ec` is an lvalue of 13 | type `const error_code` and `s` is an lvalue of type `const size_t`. 14 | 15 | [endsect] 16 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server/header.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // header.hpp 3 | // ~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 HTTP_HEADER_HPP 12 | #define HTTP_HEADER_HPP 13 | 14 | #include 15 | 16 | namespace http { 17 | namespace server { 18 | 19 | struct header 20 | { 21 | std::string name; 22 | std::string value; 23 | }; 24 | 25 | } // namespace server 26 | } // namespace http 27 | 28 | #endif // HTTP_HEADER_HPP 29 | -------------------------------------------------------------------------------- /asio/src/tests/unit/post.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // post.cpp 3 | // ~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/post.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "post", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/services/logger.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // logger.hpp 3 | // ~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 SERVICES_LOGGER_HPP 12 | #define SERVICES_LOGGER_HPP 13 | 14 | #include "basic_logger.hpp" 15 | #include "logger_service.hpp" 16 | 17 | namespace services { 18 | 19 | /// Typedef for typical logger usage. 20 | typedef basic_logger logger; 21 | 22 | } // namespace services 23 | 24 | #endif // SERVICES_LOGGER_HPP 25 | -------------------------------------------------------------------------------- /asio/src/tests/unit/defer.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // defer.cpp 3 | // ~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/defer.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "defer", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server2/header.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // header.hpp 3 | // ~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 HTTP_SERVER2_HEADER_HPP 12 | #define HTTP_SERVER2_HEADER_HPP 13 | 14 | #include 15 | 16 | namespace http { 17 | namespace server2 { 18 | 19 | struct header 20 | { 21 | std::string name; 22 | std::string value; 23 | }; 24 | 25 | } // namespace server2 26 | } // namespace http 27 | 28 | #endif // HTTP_SERVER2_HEADER_HPP 29 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server3/header.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // header.hpp 3 | // ~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 HTTP_SERVER3_HEADER_HPP 12 | #define HTTP_SERVER3_HEADER_HPP 13 | 14 | #include 15 | 16 | namespace http { 17 | namespace server3 { 18 | 19 | struct header 20 | { 21 | std::string name; 22 | std::string value; 23 | }; 24 | 25 | } // namespace server3 26 | } // namespace http 27 | 28 | #endif // HTTP_SERVER3_HEADER_HPP 29 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server4/header.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // header.hpp 3 | // ~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 HTTP_SERVER4_HEADER_HPP 12 | #define HTTP_SERVER4_HEADER_HPP 13 | 14 | #include 15 | 16 | namespace http { 17 | namespace server4 { 18 | 19 | struct header 20 | { 21 | std::string name; 22 | std::string value; 23 | }; 24 | 25 | } // namespace server4 26 | } // namespace http 27 | 28 | #endif // HTTP_SERVER4_HEADER_HPP 29 | -------------------------------------------------------------------------------- /asio/src/tests/unit/thread.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // thread.cpp 3 | // ~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/thread.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "thread", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/detached.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // detached.cpp 3 | // ~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/detached.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "detached", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/dispatch.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // dispatch.cpp 3 | // ~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/dispatch.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "dispatch", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/executor.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // executor.cpp 3 | // ~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/executor.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "executor", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/file_base.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // file_base.cpp 3 | // ~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/post.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "file_base", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ssl/error.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // error.cpp 3 | // ~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/ssl/error.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "ssl/error", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/awaitable.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // awaitable.cpp 3 | // ~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/awaitable.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "awaitable", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/immediate.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // immediate.cpp 3 | // ~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/immediate.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "immediate", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/this_coro.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // this_coro.cpp 3 | // ~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/this_coro.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "this_coro", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/tutorial/timer2/timer.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // timer.cpp 3 | // ~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include 12 | #include 13 | 14 | void print(const std::error_code& /*e*/) 15 | { 16 | std::cout << "Hello, world!" << std::endl; 17 | } 18 | 19 | int main() 20 | { 21 | asio::io_context io; 22 | 23 | asio::steady_timer t(io, asio::chrono::seconds(5)); 24 | t.async_wait(&print); 25 | 26 | io.run(); 27 | 28 | return 0; 29 | } 30 | -------------------------------------------------------------------------------- /asio/src/tests/unit/associator.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // associator.cpp 3 | // ~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/associator.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "associator", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/basic_file.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_file.cpp 3 | // ~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/basic_file.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_file", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ssl/context.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // context.cpp 3 | // ~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/ssl/context.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "ssl/context", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/deferred.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // deferred.cpp 3 | // ~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/deferred.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "experimental/deferred", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/time_traits.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // time_traits.cpp 3 | // ~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/time_traits.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "time_traits", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/wait_traits.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // wait_traits.cpp 3 | // ~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/wait_traits.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "wait_traits", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/async_result.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // async_result.cpp 3 | // ~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/async_result.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "async_result", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/basic_socket.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_socket.cpp 3 | // ~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/basic_socket.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_socket", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/placeholders.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // placeholders.cpp 3 | // ~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/placeholders.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "placeholders", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp03/can_query_not_applicable_unsupported.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp03/can_query_not_applicable_unsupported.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/query.hpp" 12 | #include 13 | 14 | struct prop 15 | { 16 | }; 17 | 18 | struct object 19 | { 20 | }; 21 | 22 | int main() 23 | { 24 | assert((!asio::can_query::value)); 25 | assert((!asio::can_query::value)); 26 | } 27 | -------------------------------------------------------------------------------- /asio/src/tests/unit/packaged_task.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // packaged_task.cpp 3 | // ~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/packaged_task.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "packaged_task", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/use_awaitable.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // use_awaitable.cpp 3 | // ~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/use_awaitable.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "use_awaitable", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/uses_executor.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // uses_executor.cpp 3 | // ~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/uses_executor.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "uses_executor", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/doc/requirements/BufferedHandshakeHandler.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | / Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | / 4 | / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | /] 7 | 8 | [section:BufferedHandshakeHandler Buffered handshake handler requirements] 9 | 10 | A buffered handshake handler must meet the requirements for a [link 11 | asio.reference.Handler handler]. A value `h` of a buffered handshake handler 12 | class should work correctly in the expression `h(ec, s)`, where `ec` is an 13 | lvalue of type `const error_code` and `s` is an lvalue of type `const size_t`. 14 | 15 | [endsect] 16 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp14/can_query_not_applicable_unsupported.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp14/can_query_not_applicable_unsupported.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/query.hpp" 12 | #include 13 | 14 | struct prop 15 | { 16 | }; 17 | 18 | struct object 19 | { 20 | }; 21 | 22 | int main() 23 | { 24 | static_assert(!asio::can_query_v, ""); 25 | static_assert(!asio::can_query_v, ""); 26 | } 27 | -------------------------------------------------------------------------------- /asio/src/tests/unit/posix/descriptor.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // descriptor.cpp 3 | // ~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/posix/descriptor.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "posix/descriptor", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ssl/stream_base.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // stream_base.cpp 3 | // ~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/ssl/stream_base.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "ssl/stream_base", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/basic_streambuf.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_streambuf.cpp 3 | // ~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/basic_streambuf.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_streambuf", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ssl/context_base.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // context_base.cpp 3 | // ~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/ssl/context_base.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "ssl/context_base", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp11/can_query_not_applicable_unsupported.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp11/can_query_not_applicable_unsupported.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/query.hpp" 12 | #include 13 | 14 | struct prop 15 | { 16 | }; 17 | 18 | struct object 19 | { 20 | }; 21 | 22 | int main() 23 | { 24 | static_assert(!asio::can_query::value, ""); 25 | static_assert(!asio::can_query::value, ""); 26 | } 27 | -------------------------------------------------------------------------------- /asio/src/tests/unit/basic_raw_socket.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_raw_socket.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/basic_raw_socket.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_raw_socket", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/basic_signal_set.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_signal_set.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/basic_signal_set.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_signal_set", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/include/asio/ts/buffer.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // ts/buffer.hpp 3 | // ~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_TS_BUFFER_HPP 12 | #define ASIO_TS_BUFFER_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/buffer.hpp" 19 | #include "asio/completion_condition.hpp" 20 | #include "asio/read.hpp" 21 | #include "asio/write.hpp" 22 | #include "asio/read_until.hpp" 23 | 24 | #endif // ASIO_TS_BUFFER_HPP 25 | -------------------------------------------------------------------------------- /asio/src/tests/unit/basic_stream_file.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_stream_file.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/basic_stream_file.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_stream_file", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/cancellation_type.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cancellation_type.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/cancellation_type.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "cancellation_type", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/execution_context.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // execution_context.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/execution_context.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "execution_context", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ip/basic_endpoint.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_endpoint.cpp 3 | // ~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/ip/basic_endpoint.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "ip/basic_endpoint", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ip/basic_resolver.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_resolver.cpp 3 | // ~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/ip/basic_resolver.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "ip/basic_resolver", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/include/asio/buffered_stream_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // buffered_stream_fwd.hpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_BUFFERED_STREAM_FWD_HPP 12 | #define ASIO_BUFFERED_STREAM_FWD_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | namespace asio { 19 | 20 | template 21 | class buffered_stream; 22 | 23 | } // namespace asio 24 | 25 | #endif // ASIO_BUFFERED_STREAM_FWD_HPP 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/cancellation_state.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cancellation_state.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/cancellation_state.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "cancellation_state", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/local/basic_endpoint.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_endpoint.cpp 3 | // ~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/local/basic_endpoint.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "local/basic_endpoint", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/include/asio/detail/cstddef.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // detail/cstddef.hpp 3 | // ~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_DETAIL_CSTDDEF_HPP 12 | #define ASIO_DETAIL_CSTDDEF_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/detail/config.hpp" 19 | #include 20 | 21 | namespace asio { 22 | 23 | using std::nullptr_t; 24 | 25 | } // namespace asio 26 | 27 | #endif // ASIO_DETAIL_CSTDDEF_HPP 28 | -------------------------------------------------------------------------------- /asio/src/tests/unit/associated_executor.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // associated_executor.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/associated_executor.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "associated_executor", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/basic_readable_pipe.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_readable_pipe.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/basic_readable_pipe.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_readable_pipe", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/basic_stream_socket.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_stream_socket.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/basic_stream_socket.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_stream_socket", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/basic_writable_pipe.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_writable_pipe.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/basic_writable_pipe.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_writable_pipe", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/buffer_registration.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // buffer_registration.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/buffer_registration.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "buffer_registration", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/cancellation_signal.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cancellation_signal.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/cancellation_signal.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "cancellation_signal", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/executor_work_guard.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // executor_work_guard.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/executor_work_guard.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "executor_work_guard", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/posix/descriptor_base.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // descriptor_base.cpp 3 | // ~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/posix/descriptor_base.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "posix/descriptor_base", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/include/asio/version.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // version.hpp 3 | // ~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_VERSION_HPP 12 | #define ASIO_VERSION_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | // ASIO_VERSION % 100 is the sub-minor version 19 | // ASIO_VERSION / 100 % 1000 is the minor version 20 | // ASIO_VERSION / 100000 is the major version 21 | #define ASIO_VERSION 103402 // 1.34.2 22 | 23 | #endif // ASIO_VERSION_HPP 24 | -------------------------------------------------------------------------------- /asio/src/tests/unit/associated_allocator.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // associated_allocator.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/associated_allocator.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "associated_allocator", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/basic_deadline_timer.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_deadline_timer.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/basic_deadline_timer.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_deadline_timer", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/basic_waitable_timer.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_waitable_timer.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/basic_waitable_timer.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_waitable_timer", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/completion_condition.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // completion_condition.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/completion_condition.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "completion_condition", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/posix/basic_descriptor.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_descriptor.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/posix/basic_descriptor.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "posix/basic_descriptor", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/Makefile.am: -------------------------------------------------------------------------------- 1 | if HAVE_CXX11 2 | EXAMPLES_CPP11 = examples/cpp11 3 | endif 4 | 5 | if HAVE_CXX14 6 | EXAMPLES_CPP14 = examples/cpp14 7 | endif 8 | 9 | if HAVE_CXX17 10 | EXAMPLES_CPP17 = examples/cpp17 11 | endif 12 | 13 | if HAVE_CXX20 14 | EXAMPLES_CPP20 = examples/cpp20 15 | endif 16 | 17 | SUBDIRS = \ 18 | $(EXAMPLES_CPP11) \ 19 | $(EXAMPLES_CPP14) \ 20 | $(EXAMPLES_CPP17) \ 21 | $(EXAMPLES_CPP20) \ 22 | tests 23 | 24 | DIST_SUBDIRS = \ 25 | examples/cpp11 \ 26 | examples/cpp14 \ 27 | examples/cpp17 \ 28 | examples/cpp20 \ 29 | tests 30 | 31 | EXTRA_DIST = \ 32 | Makefile.mgw \ 33 | Makefile.msc \ 34 | tools/handlerlive.pl \ 35 | tools/handlertree.pl \ 36 | tools/handlerviz.pl 37 | 38 | MAINTAINERCLEANFILES = \ 39 | $(srcdir)/Makefile.in 40 | -------------------------------------------------------------------------------- /asio/src/doc/requirements/MoveAcceptHandler.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | / Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | / 4 | / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | /] 7 | 8 | [section:MoveAcceptHandler Move accept handler requirements] 9 | 10 | A move accept handler must meet the requirements for a [link 11 | asio.reference.Handler handler]. A value `h` of a move accept handler class 12 | should work correctly in the expression `h(ec, s)`, where `ec` is an lvalue of 13 | type `const error_code` and `s` is an lvalue of the nested type 14 | `Protocol::socket` for the type `Protocol` of the socket class template. 15 | 16 | [endsect] 17 | -------------------------------------------------------------------------------- /asio/src/tests/unit/basic_datagram_socket.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_datagram_socket.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/basic_datagram_socket.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_datagram_socket", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/basic_socket_acceptor.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_socket_acceptor.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/basic_socket_acceptor.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_socket_acceptor", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp14/can_query_not_applicable_member.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp14/can_query_not_applicable_member.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/query.hpp" 12 | #include 13 | 14 | struct prop 15 | { 16 | }; 17 | 18 | struct object 19 | { 20 | constexpr int query(prop) const { return 123; } 21 | }; 22 | 23 | int main() 24 | { 25 | static_assert(!asio::can_query_v, ""); 26 | static_assert(!asio::can_query_v, ""); 27 | } 28 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp14/can_query_unsupported.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp14/can_query_unsupported.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/query.hpp" 12 | #include 13 | 14 | struct prop 15 | { 16 | template static constexpr bool is_applicable_property_v = true; 17 | }; 18 | 19 | struct object 20 | { 21 | }; 22 | 23 | int main() 24 | { 25 | static_assert(!asio::can_query_v, ""); 26 | static_assert(!asio::can_query_v, ""); 27 | } 28 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ip/resolver_query_base.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // resolver_query_base.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/ip/resolver_query_base.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "ip/resolver_query_base", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/doc/doxy2qbk.pl: -------------------------------------------------------------------------------- 1 | #!/usr/bin/perl -w 2 | 3 | # Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | 8 | use strict; 9 | 10 | system("doxygen reference.dox"); 11 | chdir("xml"); 12 | system("xsltproc combine.xslt index.xml > all.xml"); 13 | chdir(".."); 14 | system("xsltproc reference.xsl xml/all.xml > reference.qbk"); 15 | system("rm -rf xml"); 16 | 17 | system("doxygen tutorial.dox"); 18 | chdir("xml"); 19 | system("xsltproc combine.xslt index.xml > all.xml"); 20 | chdir(".."); 21 | system("xsltproc tutorial.xsl xml/all.xml > tutorial.qbk"); 22 | system("rm -rf xml reference.tags"); 23 | -------------------------------------------------------------------------------- /asio/src/tests/unit/basic_seq_packet_socket.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_seq_packet_socket.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/basic_seq_packet_socket.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_seq_packet_socket", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/generic/basic_endpoint.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // generic/basic_endpoint.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/generic/basic_endpoint.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "generic/basic_endpoint", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ip/basic_resolver_entry.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_resolver_entry.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/ip/basic_resolver_entry.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "ip/basic_resolver_entry", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ip/basic_resolver_query.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_resolver_query.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/ip/basic_resolver_query.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "ip/basic_resolver_query", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/windows/basic_object_handle.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_object_handle.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/windows/basic_object_handle.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_object_handle", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/windows/basic_stream_handle.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_stream_handle.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/windows/basic_stream_handle.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_stream_handle", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/doc/requirements/IteratorConnectHandler.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | / Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | / 4 | / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | /] 7 | 8 | [section:IteratorConnectHandler Iterator connect handler requirements] 9 | 10 | An iterator connect handler must meet the requirements for a [link 11 | asio.reference.Handler handler]. A value `h` of an iterator connect handler 12 | class should work correctly in the expression `h(ec, i)`, where `ec` is an 13 | lvalue of type `const error_code` and `i` is an lvalue of the type `Iterator` 14 | used in the corresponding `async_connect()` function. 15 | 16 | [endsect] 17 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server/mime_types.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // mime_types.hpp 3 | // ~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 HTTP_MIME_TYPES_HPP 12 | #define HTTP_MIME_TYPES_HPP 13 | 14 | #include 15 | 16 | namespace http { 17 | namespace server { 18 | namespace mime_types { 19 | 20 | /// Convert a file extension into a MIME type. 21 | std::string extension_to_type(const std::string& extension); 22 | 23 | } // namespace mime_types 24 | } // namespace server 25 | } // namespace http 26 | 27 | #endif // HTTP_MIME_TYPES_HPP 28 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp11/can_query_not_applicable_member.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp11/can_query_not_applicable_member.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/query.hpp" 12 | #include 13 | 14 | struct prop 15 | { 16 | }; 17 | 18 | struct object 19 | { 20 | constexpr int query(prop) const { return 123; } 21 | }; 22 | 23 | int main() 24 | { 25 | static_assert(!asio::can_query::value, ""); 26 | static_assert(!asio::can_query::value, ""); 27 | } 28 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp14/can_query_not_applicable_free.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp14/can_query_not_applicable_free.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/query.hpp" 12 | #include 13 | 14 | struct prop 15 | { 16 | }; 17 | 18 | struct object 19 | { 20 | friend constexpr int query(const object&, prop) { return 123; } 21 | }; 22 | 23 | int main() 24 | { 25 | static_assert(!asio::can_query_v, ""); 26 | static_assert(!asio::can_query_v, ""); 27 | } 28 | -------------------------------------------------------------------------------- /asio/src/tests/unit/archetypes/io_control_command.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // io_control_command.hpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ARCHETYPES_IO_CONTROL_COMMAND_HPP 12 | #define ARCHETYPES_IO_CONTROL_COMMAND_HPP 13 | 14 | namespace archetypes { 15 | 16 | class io_control_command 17 | { 18 | public: 19 | int name() const 20 | { 21 | return 0; 22 | } 23 | 24 | void* data() 25 | { 26 | return 0; 27 | } 28 | }; 29 | 30 | } // namespace archetypes 31 | 32 | #endif // ARCHETYPES_IO_CONTROL_COMMAND_HPP 33 | -------------------------------------------------------------------------------- /asio/src/tests/unit/basic_random_access_file.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_random_access_file.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/basic_random_access_file.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_random_access_file", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/execution/invocable_archetype.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // invocable_archetype.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/execution/invocable_archetype.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "invocable_archetype", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/include/asio/buffered_read_stream_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // buffered_read_stream_fwd.hpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_BUFFERED_READ_STREAM_FWD_HPP 12 | #define ASIO_BUFFERED_READ_STREAM_FWD_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | namespace asio { 19 | 20 | template 21 | class buffered_read_stream; 22 | 23 | } // namespace asio 24 | 25 | #endif // ASIO_BUFFERED_READ_STREAM_FWD_HPP 26 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/type_erasure/sleep.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // sleep.cpp 3 | // ~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "sleep.hpp" 12 | #include 13 | #include 14 | #include 15 | 16 | void async_sleep_impl( 17 | asio::any_completion_handler handler, 18 | asio::any_io_executor ex, std::chrono::nanoseconds duration) 19 | { 20 | auto timer = std::make_shared(ex, duration); 21 | timer->async_wait(asio::consign(std::move(handler), timer)); 22 | } 23 | -------------------------------------------------------------------------------- /asio/src/examples/cpp20/type_erasure/sleep.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // sleep.cpp 3 | // ~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "sleep.hpp" 12 | #include 13 | #include 14 | #include 15 | 16 | void async_sleep_impl( 17 | asio::any_completion_handler handler, 18 | asio::any_io_executor ex, std::chrono::nanoseconds duration) 19 | { 20 | auto timer = std::make_shared(ex, duration); 21 | timer->async_wait(asio::consign(std::move(handler), timer)); 22 | } 23 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp14/can_query_not_applicable_static.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp14/can_query_not_applicable_static.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/query.hpp" 12 | #include 13 | 14 | struct prop 15 | { 16 | template static constexpr int static_query_v = 123; 17 | }; 18 | 19 | struct object 20 | { 21 | }; 22 | 23 | int main() 24 | { 25 | static_assert(!asio::can_query_v, ""); 26 | static_assert(!asio::can_query_v, ""); 27 | } 28 | -------------------------------------------------------------------------------- /asio/src/tests/unit/experimental/co_composed.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // experimental/co_composed.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/experimental/co_composed.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "experimental/co_composed", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ssl/host_name_verification.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // host_name_verification.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/ssl/host_name_verification.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "ssl/host_name_verification", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/include/asio/buffered_write_stream_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // buffered_write_stream_fwd.hpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_BUFFERED_WRITE_STREAM_FWD_HPP 12 | #define ASIO_BUFFERED_WRITE_STREAM_FWD_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | namespace asio { 19 | 20 | template 21 | class buffered_write_stream; 22 | 23 | } // namespace asio 24 | 25 | #endif // ASIO_BUFFERED_WRITE_STREAM_FWD_HPP 26 | -------------------------------------------------------------------------------- /asio/src/doc/requirements/RangeConnectHandler.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | / Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | / 4 | / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | /] 7 | 8 | [section:RangeConnectHandler Range connect handler requirements] 9 | 10 | A range connect handler must meet the requirements for a [link 11 | asio.reference.Handler handler]. A value `h` of a range connect handler class 12 | should work correctly in the expression `h(ec, ep)`, where `ec` is an lvalue of 13 | type `const error_code` and `ep` is an lvalue of the type `Protocol::endpoint` 14 | for the `Protocol` type in the corresponding `async_connect()` function. 15 | 16 | [endsect] 17 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp11/can_query_not_applicable_free.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp11/can_query_not_applicable_free.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/query.hpp" 12 | #include 13 | 14 | struct prop 15 | { 16 | }; 17 | 18 | struct object 19 | { 20 | friend constexpr int query(const object&, prop) { return 123; } 21 | }; 22 | 23 | int main() 24 | { 25 | static_assert(!asio::can_query::value, ""); 26 | static_assert(!asio::can_query::value, ""); 27 | } 28 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ip/basic_resolver_iterator.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_resolver_iterator.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/ip/basic_resolver_iterator.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "ip/basic_resolver_iterator", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/include/asio/detail/array.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // detail/array.hpp 3 | // ~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_DETAIL_ARRAY_HPP 12 | #define ASIO_DETAIL_ARRAY_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/detail/config.hpp" 19 | 20 | #include 21 | 22 | namespace asio { 23 | namespace detail { 24 | 25 | using std::array; 26 | 27 | } // namespace detail 28 | } // namespace asio 29 | 30 | #endif // ASIO_DETAIL_ARRAY_HPP 31 | -------------------------------------------------------------------------------- /asio/src/tests/unit/experimental/basic_channel.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // experimental/basic_channel.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/experimental/basic_channel.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "experimental/basic_channel", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/posix/basic_stream_descriptor.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_stream_descriptor.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/posix/basic_stream_descriptor.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "posix/basic_stream_descriptor", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/windows/basic_overlapped_handle.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_overlapped_handle.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/windows/basic_overlapped_handle.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_overlapped_handle", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/associated_cancellation_slot.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // associated_cancellation_slot.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/associated_cancellation_slot.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "associated_cancellation_slot", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/experimental/channel_traits.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // experimental/channel_traits.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/experimental/channel_traits.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "experimental/channel_traits", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/experimental/parallel_group.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // experimental/parallel_group.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/experimental/parallel_group.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "experimental/parallel_group", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/windows/overlapped_handle.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // overlapped_handle.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/windows/overlapped_handle.hpp" 18 | 19 | #include "asio.hpp" 20 | #include "../unit_test.hpp" 21 | 22 | ASIO_TEST_SUITE 23 | ( 24 | "windows/overlapped_handle", 25 | ASIO_TEST_CASE(null_test) 26 | ) 27 | -------------------------------------------------------------------------------- /asio/include/asio/ts/net.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // ts/net.hpp 3 | // ~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_TS_NET_HPP 12 | #define ASIO_TS_NET_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/ts/netfwd.hpp" 19 | #include "asio/ts/executor.hpp" 20 | #include "asio/ts/io_context.hpp" 21 | #include "asio/ts/timer.hpp" 22 | #include "asio/ts/buffer.hpp" 23 | #include "asio/ts/socket.hpp" 24 | #include "asio/ts/internet.hpp" 25 | 26 | #endif // ASIO_TS_NET_HPP 27 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server2/mime_types.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // mime_types.hpp 3 | // ~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 HTTP_SERVER2_MIME_TYPES_HPP 12 | #define HTTP_SERVER2_MIME_TYPES_HPP 13 | 14 | #include 15 | 16 | namespace http { 17 | namespace server2 { 18 | namespace mime_types { 19 | 20 | /// Convert a file extension into a MIME type. 21 | std::string extension_to_type(const std::string& extension); 22 | 23 | } // namespace mime_types 24 | } // namespace server2 25 | } // namespace http 26 | 27 | #endif // HTTP_SERVER2_MIME_TYPES_HPP 28 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server3/mime_types.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // mime_types.hpp 3 | // ~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 HTTP_SERVER3_MIME_TYPES_HPP 12 | #define HTTP_SERVER3_MIME_TYPES_HPP 13 | 14 | #include 15 | 16 | namespace http { 17 | namespace server3 { 18 | namespace mime_types { 19 | 20 | /// Convert a file extension into a MIME type. 21 | std::string extension_to_type(const std::string& extension); 22 | 23 | } // namespace mime_types 24 | } // namespace server3 25 | } // namespace http 26 | 27 | #endif // HTTP_SERVER3_MIME_TYPES_HPP 28 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server4/mime_types.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // mime_types.hpp 3 | // ~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 HTTP_SERVER4_MIME_TYPES_HPP 12 | #define HTTP_SERVER4_MIME_TYPES_HPP 13 | 14 | #include 15 | 16 | namespace http { 17 | namespace server4 { 18 | namespace mime_types { 19 | 20 | /// Convert a file extension into a MIME type. 21 | std::string extension_to_type(const std::string& extension); 22 | 23 | } // namespace mime_types 24 | } // namespace server4 25 | } // namespace http 26 | 27 | #endif // HTTP_SERVER4_MIME_TYPES_HPP 28 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp14/can_query_member.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp14/can_query_member.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/query.hpp" 12 | #include 13 | 14 | struct prop 15 | { 16 | template static constexpr bool is_applicable_property_v = true; 17 | }; 18 | 19 | struct object 20 | { 21 | constexpr int query(prop) const { return 123; } 22 | }; 23 | 24 | int main() 25 | { 26 | static_assert(asio::can_query_v, ""); 27 | static_assert(asio::can_query_v, ""); 28 | } 29 | -------------------------------------------------------------------------------- /asio/src/tests/unit/associated_immediate_executor.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // associated_immediate_executor.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2022 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/associated_immediate_executor.hpp" 18 | 19 | #include "unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "associated_immediate_executor", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/unit/windows/basic_random_access_handle.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_random_access_handle.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/windows/basic_random_access_handle.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "basic_random_access_handle", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/include/asio/ts/timer.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // ts/timer.hpp 3 | // ~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_TS_TIMER_HPP 12 | #define ASIO_TS_TIMER_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/detail/chrono.hpp" 19 | 20 | #include "asio/wait_traits.hpp" 21 | #include "asio/basic_waitable_timer.hpp" 22 | #include "asio/system_timer.hpp" 23 | #include "asio/steady_timer.hpp" 24 | #include "asio/high_resolution_timer.hpp" 25 | 26 | #endif // ASIO_TS_TIMER_HPP 27 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp14/can_query_free.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp14/can_query_free.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/query.hpp" 12 | #include 13 | 14 | struct prop 15 | { 16 | template static constexpr bool is_applicable_property_v = true; 17 | }; 18 | 19 | struct object 20 | { 21 | friend constexpr int query(const object&, prop) { return 123; } 22 | }; 23 | 24 | int main() 25 | { 26 | static_assert(asio::can_query_v, ""); 27 | static_assert(asio::can_query_v, ""); 28 | } 29 | -------------------------------------------------------------------------------- /asio/include/asio/signal_set.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // signal_set.hpp 3 | // ~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_SIGNAL_SET_HPP 12 | #define ASIO_SIGNAL_SET_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/detail/config.hpp" 19 | #include "asio/basic_signal_set.hpp" 20 | 21 | namespace asio { 22 | 23 | /// Typedef for the typical usage of a signal set. 24 | typedef basic_signal_set<> signal_set; 25 | 26 | } // namespace asio 27 | 28 | #endif // ASIO_SIGNAL_SET_HPP 29 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp14/can_query_static.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp14/can_query_static.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/query.hpp" 12 | #include 13 | 14 | struct prop 15 | { 16 | template static constexpr bool is_applicable_property_v = true; 17 | template static constexpr int static_query_v = 123; 18 | }; 19 | 20 | struct object 21 | { 22 | }; 23 | 24 | int main() 25 | { 26 | static_assert(asio::can_query_v, ""); 27 | static_assert(asio::can_query_v, ""); 28 | } 29 | -------------------------------------------------------------------------------- /asio/src/tests/unit/basic_serial_port.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // basic_serial_port.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 6 | // Copyright (c) 2008 Rep Invariant Systems, Inc. (info@repinvariant.com) 7 | // 8 | // Distributed under the Boost Software License, Version 1.0. (See accompanying 9 | // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 10 | // 11 | 12 | // Disable autolinking for unit tests. 13 | #if !defined(BOOST_ALL_NO_LIB) 14 | #define BOOST_ALL_NO_LIB 1 15 | #endif // !defined(BOOST_ALL_NO_LIB) 16 | 17 | // Test that header file is self-contained. 18 | #include "asio/basic_serial_port.hpp" 19 | 20 | #include "unit_test.hpp" 21 | 22 | ASIO_TEST_SUITE 23 | ( 24 | "basic_serial_port", 25 | ASIO_TEST_CASE(null_test) 26 | ) 27 | -------------------------------------------------------------------------------- /asio/include/asio/detail/exception.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // detail/exception.hpp 3 | // ~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_DETAIL_EXCEPTION_HPP 12 | #define ASIO_DETAIL_EXCEPTION_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/detail/config.hpp" 19 | #include 20 | 21 | namespace asio { 22 | 23 | using std::exception_ptr; 24 | using std::current_exception; 25 | using std::rethrow_exception; 26 | 27 | } // namespace asio 28 | 29 | #endif // ASIO_DETAIL_EXCEPTION_HPP 30 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp03/can_require_concept_not_applicable_unsupported.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp03/can_require_concept_not_applicable_unsupported.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/require_concept.hpp" 12 | #include 13 | 14 | template 15 | struct prop 16 | { 17 | }; 18 | 19 | template 20 | struct object 21 | { 22 | }; 23 | 24 | int main() 25 | { 26 | assert((!asio::can_require_concept, prop<2> >::value)); 27 | assert((!asio::can_require_concept, prop<2> >::value)); 28 | } 29 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp14/can_require_concept_not_applicable_unsupported.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp14/can_require_concept_not_applicable_unsupported.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/require_concept.hpp" 12 | #include 13 | 14 | template 15 | struct prop 16 | { 17 | }; 18 | 19 | template 20 | struct object 21 | { 22 | }; 23 | 24 | int main() 25 | { 26 | static_assert(!asio::can_require_concept_v, prop<2>>, ""); 27 | static_assert(!asio::can_require_concept_v, prop<2>>, ""); 28 | } 29 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ip/address_v4_range.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // address_v4_range.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/ip/address_v4_range.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | //------------------------------------------------------------------------------ 22 | 23 | ASIO_TEST_SUITE 24 | ( 25 | "ip/address_v4_range", 26 | ASIO_TEST_CASE(null_test) 27 | ) 28 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ip/address_v6_range.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // address_v6_range.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/ip/address_v6_range.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | //------------------------------------------------------------------------------ 22 | 23 | ASIO_TEST_SUITE 24 | ( 25 | "ip/address_v6_range", 26 | ASIO_TEST_CASE(null_test) 27 | ) 28 | -------------------------------------------------------------------------------- /asio/src/tests/unit/experimental/basic_concurrent_channel.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // experimental/basic_concurrent_channel.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/experimental/basic_concurrent_channel.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | ASIO_TEST_SUITE 22 | ( 23 | "experimental/basic_concurrent_channel", 24 | ASIO_TEST_CASE(null_test) 25 | ) 26 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp11/can_require_concept_not_applicable_unsupported.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp11/can_require_concept_not_applicable_unsupported.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/require_concept.hpp" 12 | #include 13 | 14 | template 15 | struct prop 16 | { 17 | }; 18 | 19 | template 20 | struct object 21 | { 22 | }; 23 | 24 | int main() 25 | { 26 | static_assert(!asio::can_require_concept, prop<2>>::value, ""); 27 | static_assert(!asio::can_require_concept, prop<2>>::value, ""); 28 | } 29 | -------------------------------------------------------------------------------- /asio/include/asio/ssl.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // ssl.hpp 3 | // ~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_SSL_HPP 12 | #define ASIO_SSL_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/ssl/context.hpp" 19 | #include "asio/ssl/context_base.hpp" 20 | #include "asio/ssl/error.hpp" 21 | #include "asio/ssl/host_name_verification.hpp" 22 | #include "asio/ssl/stream.hpp" 23 | #include "asio/ssl/stream_base.hpp" 24 | #include "asio/ssl/verify_context.hpp" 25 | #include "asio/ssl/verify_mode.hpp" 26 | 27 | #endif // ASIO_SSL_HPP 28 | -------------------------------------------------------------------------------- /asio/src/doc/requirements/Handler.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | / Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | / 4 | / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | /] 7 | 8 | [section:Handler Handlers] 9 | 10 | A handler must satisfy the requirements of `Destructible` (C++Std 11 | [destructible]) and `MoveConstructible` (C++Std [moveconstructible]). 12 | 13 | A handler may expose additional information and behaviour via [link 14 | asio.overview.model.associators associators], such as [link 15 | asio.reference.associated_allocator `associated_allocator`], [link 16 | asio.reference.associated_executor `associated_executor`], and [link 17 | asio.reference.associated_cancellation_slot `associated_cancellation_slot`]. 18 | 19 | [endsect] 20 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server/request.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // request.hpp 3 | // ~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 HTTP_REQUEST_HPP 12 | #define HTTP_REQUEST_HPP 13 | 14 | #include 15 | #include 16 | #include "header.hpp" 17 | 18 | namespace http { 19 | namespace server { 20 | 21 | /// A request received from a client. 22 | struct request 23 | { 24 | std::string method; 25 | std::string uri; 26 | int http_version_major; 27 | int http_version_minor; 28 | std::vector
headers; 29 | }; 30 | 31 | } // namespace server 32 | } // namespace http 33 | 34 | #endif // HTTP_REQUEST_HPP 35 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ip/address_v4_iterator.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // address_v4_iterator.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/ip/address_v4_iterator.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | //------------------------------------------------------------------------------ 22 | 23 | ASIO_TEST_SUITE 24 | ( 25 | "ip/address_v4_iterator", 26 | ASIO_TEST_CASE(null_test) 27 | ) 28 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ip/address_v6_iterator.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // address_v6_iterator.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Test that header file is self-contained. 17 | #include "asio/ip/address_v6_iterator.hpp" 18 | 19 | #include "../unit_test.hpp" 20 | 21 | //------------------------------------------------------------------------------ 22 | 23 | ASIO_TEST_SUITE 24 | ( 25 | "ip/address_v6_iterator", 26 | ASIO_TEST_CASE(null_test) 27 | ) 28 | -------------------------------------------------------------------------------- /asio/include/asio/system_error.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // system_error.hpp 3 | // ~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_SYSTEM_ERROR_HPP 12 | #define ASIO_SYSTEM_ERROR_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/detail/config.hpp" 19 | #include 20 | 21 | #include "asio/detail/push_options.hpp" 22 | 23 | namespace asio { 24 | 25 | typedef std::system_error system_error; 26 | 27 | } // namespace asio 28 | 29 | #include "asio/detail/pop_options.hpp" 30 | 31 | #endif // ASIO_SYSTEM_ERROR_HPP 32 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp03/can_query_unsupported.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp03/can_query_unsupported.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/query.hpp" 12 | #include 13 | 14 | struct prop 15 | { 16 | }; 17 | 18 | struct object 19 | { 20 | }; 21 | 22 | namespace asio { 23 | 24 | template <> 25 | struct is_applicable_property 26 | { 27 | static const bool value = true; 28 | }; 29 | 30 | } // namespace asio 31 | 32 | int main() 33 | { 34 | assert((!asio::can_query::value)); 35 | assert((!asio::can_query::value)); 36 | } 37 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/deferred/deferred_1.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // deferred_1.cpp 3 | // ~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include 12 | #include 13 | 14 | using asio::deferred; 15 | 16 | int main() 17 | { 18 | asio::io_context ctx; 19 | 20 | asio::steady_timer timer(ctx); 21 | timer.expires_after(std::chrono::seconds(1)); 22 | 23 | auto deferred_op = timer.async_wait(deferred); 24 | 25 | std::move(deferred_op)( 26 | [](std::error_code ec) 27 | { 28 | std::cout << "timer wait finished: " << ec.message() << "\n"; 29 | } 30 | ); 31 | 32 | ctx.run(); 33 | 34 | return 0; 35 | } 36 | -------------------------------------------------------------------------------- /asio/src/examples/cpp14/deferred/deferred_1.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // deferred_1.cpp 3 | // ~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include 12 | #include 13 | 14 | using asio::deferred; 15 | 16 | int main() 17 | { 18 | asio::io_context ctx; 19 | 20 | asio::steady_timer timer(ctx); 21 | timer.expires_after(std::chrono::seconds(1)); 22 | 23 | auto deferred_op = timer.async_wait(deferred); 24 | 25 | std::move(deferred_op)( 26 | [](std::error_code ec) 27 | { 28 | std::cout << "timer wait finished: " << ec.message() << "\n"; 29 | } 30 | ); 31 | 32 | ctx.run(); 33 | 34 | return 0; 35 | } 36 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp11/can_query_unsupported.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp11/can_query_unsupported.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/query.hpp" 12 | #include 13 | 14 | struct prop 15 | { 16 | }; 17 | 18 | struct object 19 | { 20 | }; 21 | 22 | namespace asio { 23 | 24 | template<> 25 | struct is_applicable_property 26 | { 27 | static constexpr bool value = true; 28 | }; 29 | 30 | } // namespace asio 31 | 32 | int main() 33 | { 34 | static_assert(!asio::can_query::value, ""); 35 | static_assert(!asio::can_query::value, ""); 36 | } 37 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server2/request.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // request.hpp 3 | // ~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 HTTP_SERVER2_REQUEST_HPP 12 | #define HTTP_SERVER2_REQUEST_HPP 13 | 14 | #include 15 | #include 16 | #include "header.hpp" 17 | 18 | namespace http { 19 | namespace server2 { 20 | 21 | /// A request received from a client. 22 | struct request 23 | { 24 | std::string method; 25 | std::string uri; 26 | int http_version_major; 27 | int http_version_minor; 28 | std::vector
headers; 29 | }; 30 | 31 | } // namespace server2 32 | } // namespace http 33 | 34 | #endif // HTTP_SERVER2_REQUEST_HPP 35 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server3/request.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // request.hpp 3 | // ~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 HTTP_SERVER3_REQUEST_HPP 12 | #define HTTP_SERVER3_REQUEST_HPP 13 | 14 | #include 15 | #include 16 | #include "header.hpp" 17 | 18 | namespace http { 19 | namespace server3 { 20 | 21 | /// A request received from a client. 22 | struct request 23 | { 24 | std::string method; 25 | std::string uri; 26 | int http_version_major; 27 | int http_version_minor; 28 | std::vector
headers; 29 | }; 30 | 31 | } // namespace server3 32 | } // namespace http 33 | 34 | #endif // HTTP_SERVER3_REQUEST_HPP 35 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server4/request.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // request.hpp 3 | // ~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 HTTP_SERVER4_REQUEST_HPP 12 | #define HTTP_SERVER4_REQUEST_HPP 13 | 14 | #include 15 | #include 16 | #include "header.hpp" 17 | 18 | namespace http { 19 | namespace server4 { 20 | 21 | /// A request received from a client. 22 | struct request 23 | { 24 | std::string method; 25 | std::string uri; 26 | int http_version_major; 27 | int http_version_minor; 28 | std::vector
headers; 29 | }; 30 | 31 | } // namespace server4 32 | } // namespace http 33 | 34 | #endif // HTTP_SERVER4_REQUEST_HPP 35 | -------------------------------------------------------------------------------- /asio/include/asio/detail/functional.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // detail/functional.hpp 3 | // ~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_DETAIL_FUNCTIONAL_HPP 12 | #define ASIO_DETAIL_FUNCTIONAL_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/detail/config.hpp" 19 | #include 20 | 21 | namespace asio { 22 | namespace detail { 23 | 24 | using std::function; 25 | 26 | } // namespace detail 27 | 28 | using std::ref; 29 | using std::reference_wrapper; 30 | 31 | } // namespace asio 32 | 33 | #endif // ASIO_DETAIL_FUNCTIONAL_HPP 34 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ts/net.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // net.cpp 3 | // ~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Prevent link dependency on the Boost.System library. 17 | #if !defined(BOOST_SYSTEM_NO_DEPRECATED) 18 | #define BOOST_SYSTEM_NO_DEPRECATED 19 | #endif // !defined(BOOST_SYSTEM_NO_DEPRECATED) 20 | 21 | // Test that header file is self-contained. 22 | #include "asio/ts/net.hpp" 23 | 24 | #include "../unit_test.hpp" 25 | 26 | ASIO_TEST_SUITE 27 | ( 28 | "ts/net", 29 | ASIO_TEST_CASE(null_test) 30 | ) 31 | -------------------------------------------------------------------------------- /asio/src/doc/requirements/ResolveHandler.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | / Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | / 4 | / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | /] 7 | 8 | [section:ResolveHandler Resolve handler requirements] 9 | 10 | A resolve handler must meet the requirements for a [link asio.reference.Handler 11 | handler]. A value `h` of a resolve handler class should work correctly in the 12 | expression `h(ec, r)`, where `ec` is an lvalue of type `const error_code` and 13 | `r` is an lvalue of type `const ip::basic_resolver_results`. 14 | `InternetProtocol` is the template parameter of the [link 15 | asio.reference.ip__basic_resolver `ip::basic_resolver<>`] which is used to 16 | initiate the asynchronous operation. 17 | 18 | [endsect] 19 | -------------------------------------------------------------------------------- /asio/include/asio/ssl/impl/src.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // impl/ssl/src.hpp 3 | // ~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_SSL_IMPL_SRC_HPP 12 | #define ASIO_SSL_IMPL_SRC_HPP 13 | 14 | #define ASIO_SOURCE 15 | 16 | #include "asio/detail/config.hpp" 17 | 18 | #if defined(ASIO_HEADER_ONLY) 19 | # error Do not compile Asio library source with ASIO_HEADER_ONLY defined 20 | #endif 21 | 22 | #include "asio/ssl/impl/context.ipp" 23 | #include "asio/ssl/impl/error.ipp" 24 | #include "asio/ssl/detail/impl/engine.ipp" 25 | #include "asio/ssl/detail/impl/openssl_init.ipp" 26 | #include "asio/ssl/impl/host_name_verification.ipp" 27 | 28 | #endif // ASIO_SSL_IMPL_SRC_HPP 29 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ts/timer.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // timer.cpp 3 | // ~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Prevent link dependency on the Boost.System library. 17 | #if !defined(BOOST_SYSTEM_NO_DEPRECATED) 18 | #define BOOST_SYSTEM_NO_DEPRECATED 19 | #endif // !defined(BOOST_SYSTEM_NO_DEPRECATED) 20 | 21 | // Test that header file is self-contained. 22 | #include "asio/ts/timer.hpp" 23 | 24 | #include "../unit_test.hpp" 25 | 26 | ASIO_TEST_SUITE 27 | ( 28 | "ts/timer", 29 | ASIO_TEST_CASE(null_test) 30 | ) 31 | -------------------------------------------------------------------------------- /asio/include/asio/static_thread_pool.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // static_thread_pool.hpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_STATIC_THREAD_POOL_HPP 12 | #define ASIO_STATIC_THREAD_POOL_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/detail/config.hpp" 19 | #include "asio/thread_pool.hpp" 20 | 21 | #include "asio/detail/push_options.hpp" 22 | 23 | namespace asio { 24 | 25 | typedef thread_pool static_thread_pool; 26 | 27 | } // namespace asio 28 | 29 | #include "asio/detail/pop_options.hpp" 30 | 31 | #endif // ASIO_STATIC_THREAD_POOL_HPP 32 | -------------------------------------------------------------------------------- /asio/include/asio/streambuf.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // streambuf.hpp 3 | // ~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_STREAMBUF_HPP 12 | #define ASIO_STREAMBUF_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/detail/config.hpp" 19 | 20 | #if !defined(ASIO_NO_IOSTREAM) 21 | 22 | #include "asio/basic_streambuf.hpp" 23 | 24 | namespace asio { 25 | 26 | /// Typedef for the typical usage of basic_streambuf. 27 | typedef basic_streambuf<> streambuf; 28 | 29 | } // namespace asio 30 | 31 | #endif // !defined(ASIO_NO_IOSTREAM) 32 | 33 | #endif // ASIO_STREAMBUF_HPP 34 | -------------------------------------------------------------------------------- /asio/include/asio/ts/socket.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // ts/socket.hpp 3 | // ~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_TS_SOCKET_HPP 12 | #define ASIO_TS_SOCKET_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/socket_base.hpp" 19 | #include "asio/basic_socket.hpp" 20 | #include "asio/basic_datagram_socket.hpp" 21 | #include "asio/basic_stream_socket.hpp" 22 | #include "asio/basic_socket_acceptor.hpp" 23 | #include "asio/basic_socket_streambuf.hpp" 24 | #include "asio/basic_socket_iostream.hpp" 25 | #include "asio/connect.hpp" 26 | 27 | #endif // ASIO_TS_SOCKET_HPP 28 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ts/buffer.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // buffer.cpp 3 | // ~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Prevent link dependency on the Boost.System library. 17 | #if !defined(BOOST_SYSTEM_NO_DEPRECATED) 18 | #define BOOST_SYSTEM_NO_DEPRECATED 19 | #endif // !defined(BOOST_SYSTEM_NO_DEPRECATED) 20 | 21 | // Test that header file is self-contained. 22 | #include "asio/ts/buffer.hpp" 23 | 24 | #include "../unit_test.hpp" 25 | 26 | ASIO_TEST_SUITE 27 | ( 28 | "ts/buffer", 29 | ASIO_TEST_CASE(null_test) 30 | ) 31 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ts/socket.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // socket.cpp 3 | // ~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Prevent link dependency on the Boost.System library. 17 | #if !defined(BOOST_SYSTEM_NO_DEPRECATED) 18 | #define BOOST_SYSTEM_NO_DEPRECATED 19 | #endif // !defined(BOOST_SYSTEM_NO_DEPRECATED) 20 | 21 | // Test that header file is self-contained. 22 | #include "asio/ts/socket.hpp" 23 | 24 | #include "../unit_test.hpp" 25 | 26 | ASIO_TEST_SUITE 27 | ( 28 | "ts/socket", 29 | ASIO_TEST_CASE(null_test) 30 | ) 31 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ts/executor.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // executor.cpp 3 | // ~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Prevent link dependency on the Boost.System library. 17 | #if !defined(BOOST_SYSTEM_NO_DEPRECATED) 18 | #define BOOST_SYSTEM_NO_DEPRECATED 19 | #endif // !defined(BOOST_SYSTEM_NO_DEPRECATED) 20 | 21 | // Test that header file is self-contained. 22 | #include "asio/ts/executor.hpp" 23 | 24 | #include "../unit_test.hpp" 25 | 26 | ASIO_TEST_SUITE 27 | ( 28 | "ts/executor", 29 | ASIO_TEST_CASE(null_test) 30 | ) 31 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ts/internet.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // internet.cpp 3 | // ~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Prevent link dependency on the Boost.System library. 17 | #if !defined(BOOST_SYSTEM_NO_DEPRECATED) 18 | #define BOOST_SYSTEM_NO_DEPRECATED 19 | #endif // !defined(BOOST_SYSTEM_NO_DEPRECATED) 20 | 21 | // Test that header file is self-contained. 22 | #include "asio/ts/internet.hpp" 23 | 24 | #include "../unit_test.hpp" 25 | 26 | ASIO_TEST_SUITE 27 | ( 28 | "ts/internet", 29 | ASIO_TEST_CASE(null_test) 30 | ) 31 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp11/can_query_member.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp11/can_query_member.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/query.hpp" 12 | #include 13 | 14 | struct prop 15 | { 16 | }; 17 | 18 | struct object 19 | { 20 | constexpr int query(prop) const { return 123; } 21 | }; 22 | 23 | namespace asio { 24 | 25 | template<> 26 | struct is_applicable_property 27 | { 28 | static constexpr bool value = true; 29 | }; 30 | 31 | } // namespace asio 32 | 33 | int main() 34 | { 35 | static_assert(asio::can_query::value, ""); 36 | static_assert(asio::can_query::value, ""); 37 | } 38 | -------------------------------------------------------------------------------- /asio/src/tests/unit/steady_timer.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // steady_timer.cpp 3 | // ~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Prevent link dependency on the Boost.System library. 17 | #if !defined(BOOST_SYSTEM_NO_DEPRECATED) 18 | #define BOOST_SYSTEM_NO_DEPRECATED 19 | #endif // !defined(BOOST_SYSTEM_NO_DEPRECATED) 20 | 21 | // Test that header file is self-contained. 22 | #include "asio/steady_timer.hpp" 23 | 24 | #include "unit_test.hpp" 25 | 26 | ASIO_TEST_SUITE 27 | ( 28 | "steady_timer", 29 | ASIO_TEST_CASE(null_test) 30 | ) 31 | -------------------------------------------------------------------------------- /asio/src/doc/makepdf.pl: -------------------------------------------------------------------------------- 1 | #!/usr/bin/perl -w 2 | 3 | # Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | 8 | use strict; 9 | 10 | # Determine version number 11 | my $version = "X.Y.Z"; 12 | open(VERSION, "../../include/asio/version.hpp") or die("Can't open version.hpp"); 13 | while (my $line = ) 14 | { 15 | if ($line =~ /^#define ASIO_VERSION .* \/\/ (.*)$/) 16 | { 17 | $version = $1; 18 | } 19 | } 20 | close(VERSION); 21 | 22 | # Generate PDF output 23 | system("bjam asioref"); 24 | system("xsltproc --stringparam asio.version $version asioref.xsl asio.docbook > asioref.docbook"); 25 | system("dblatex -I overview -s asioref.sty -P table.in.float=0 -o asioref-$version.pdf asioref.docbook"); 26 | system("rm asioref.docbook"); 27 | -------------------------------------------------------------------------------- /asio/src/tests/unit/ts/io_context.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // io_context.cpp 3 | // ~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Prevent link dependency on the Boost.System library. 17 | #if !defined(BOOST_SYSTEM_NO_DEPRECATED) 18 | #define BOOST_SYSTEM_NO_DEPRECATED 19 | #endif // !defined(BOOST_SYSTEM_NO_DEPRECATED) 20 | 21 | // Test that header file is self-contained. 22 | #include "asio/ts/io_context.hpp" 23 | 24 | #include "../unit_test.hpp" 25 | 26 | ASIO_TEST_SUITE 27 | ( 28 | "ts/io_context", 29 | ASIO_TEST_CASE(null_test) 30 | ) 31 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp11/can_query_free.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp11/can_query_free.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/query.hpp" 12 | #include 13 | 14 | struct prop 15 | { 16 | }; 17 | 18 | struct object 19 | { 20 | friend constexpr int query(const object&, prop) { return 123; } 21 | }; 22 | 23 | namespace asio { 24 | 25 | template<> 26 | struct is_applicable_property 27 | { 28 | static constexpr bool value = true; 29 | }; 30 | 31 | } // namespace asio 32 | 33 | int main() 34 | { 35 | static_assert(asio::can_query::value, ""); 36 | static_assert(asio::can_query::value, ""); 37 | } 38 | -------------------------------------------------------------------------------- /asio/src/tests/unit/system_context.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // system_context.cpp 3 | // ~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Prevent link dependency on the Boost.System library. 17 | #if !defined(BOOST_SYSTEM_NO_DEPRECATED) 18 | #define BOOST_SYSTEM_NO_DEPRECATED 19 | #endif // !defined(BOOST_SYSTEM_NO_DEPRECATED) 20 | 21 | // Test that header file is self-contained. 22 | #include "asio/system_context.hpp" 23 | 24 | #include "unit_test.hpp" 25 | 26 | ASIO_TEST_SUITE 27 | ( 28 | "system_context", 29 | ASIO_TEST_CASE(null_test) 30 | ) 31 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/type_erasure/stdin_line_reader.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // stdin_line_reader.hpp 3 | // ~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 STDIN_LINE_READER_HPP 12 | #define STDIN_LINE_READER_HPP 13 | 14 | #include "line_reader.hpp" 15 | #include 16 | 17 | class stdin_line_reader : public line_reader 18 | { 19 | public: 20 | explicit stdin_line_reader(asio::any_io_executor ex); 21 | 22 | private: 23 | void async_read_line_impl(std::string prompt, 24 | asio::any_completion_handler handler) override; 25 | 26 | asio::posix::stream_descriptor stdin_; 27 | std::string buffer_; 28 | }; 29 | 30 | #endif 31 | -------------------------------------------------------------------------------- /asio/src/examples/cpp20/type_erasure/stdin_line_reader.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // stdin_line_reader.hpp 3 | // ~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 STDIN_LINE_READER_HPP 12 | #define STDIN_LINE_READER_HPP 13 | 14 | #include "line_reader.hpp" 15 | #include 16 | 17 | class stdin_line_reader : public line_reader 18 | { 19 | public: 20 | explicit stdin_line_reader(asio::any_io_executor ex); 21 | 22 | private: 23 | void async_read_line_impl(std::string prompt, 24 | asio::any_completion_handler handler) override; 25 | 26 | asio::posix::stream_descriptor stdin_; 27 | std::string buffer_; 28 | }; 29 | 30 | #endif 31 | -------------------------------------------------------------------------------- /asio/src/tests/unit/signal_set_base.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // signal_set_base.cpp 3 | // ~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Prevent link dependency on the Boost.System library. 17 | #if !defined(BOOST_SYSTEM_NO_DEPRECATED) 18 | #define BOOST_SYSTEM_NO_DEPRECATED 19 | #endif // !defined(BOOST_SYSTEM_NO_DEPRECATED) 20 | 21 | // Test that header file is self-contained. 22 | #include "asio/signal_set_base.hpp" 23 | 24 | #include "unit_test.hpp" 25 | 26 | ASIO_TEST_SUITE 27 | ( 28 | "signal_set_base", 29 | ASIO_TEST_CASE(null_test) 30 | ) 31 | -------------------------------------------------------------------------------- /asio/include/asio/detail/date_time_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // detail/date_time_fwd.hpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_DETAIL_DATE_TIME_FWD_HPP 12 | #define ASIO_DETAIL_DATE_TIME_FWD_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/detail/config.hpp" 19 | 20 | namespace boost { 21 | namespace date_time { 22 | 23 | template 24 | class base_time; 25 | 26 | } // namespace date_time 27 | namespace posix_time { 28 | 29 | class ptime; 30 | 31 | } // namespace posix_time 32 | } // namespace boost 33 | 34 | #endif // ASIO_DETAIL_DATE_TIME_FWD_HPP 35 | -------------------------------------------------------------------------------- /asio/src/tests/unit/static_thread_pool.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // static_thread_pool.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Prevent link dependency on the Boost.System library. 17 | #if !defined(BOOST_SYSTEM_NO_DEPRECATED) 18 | #define BOOST_SYSTEM_NO_DEPRECATED 19 | #endif // !defined(BOOST_SYSTEM_NO_DEPRECATED) 20 | 21 | // Test that header file is self-contained. 22 | #include "asio/static_thread_pool.hpp" 23 | 24 | #include "unit_test.hpp" 25 | 26 | ASIO_TEST_SUITE 27 | ( 28 | "static_thread_pool", 29 | ASIO_TEST_CASE(null_test) 30 | ) 31 | -------------------------------------------------------------------------------- /asio/src/doc/requirements/ProtoAllocator.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | / Copyright (c) 2003-2025 Christopher M. Kohlhoff (chris at kohlhoff dot com) 3 | / 4 | / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 | / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 | /] 7 | 8 | [section:ProtoAllocator Proto-allocator requirements] 9 | 10 | A type `A` meets the proto-allocator requirements if `A` is `CopyConstructible` 11 | (C++Std [copyconstructible]), `Destructible` (C++Std [destructible]), and 12 | `allocator_traits::rebind_alloc` meets the allocator requirements (C++Std 13 | [allocator.requirements]), where `U` is an object type. [inline_note For 14 | example, `std::allocator` meets the proto-allocator requirements but not 15 | the allocator requirements.] No constructor, comparison operator, copy 16 | operation, move operation, or swap operation on these types shall exit via an 17 | exception. 18 | 19 | [endsect] 20 | -------------------------------------------------------------------------------- /asio/include/asio/impl/system_context.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // impl/system_context.hpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_IMPL_SYSTEM_CONTEXT_HPP 12 | #define ASIO_IMPL_SYSTEM_CONTEXT_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/system_executor.hpp" 19 | 20 | #include "asio/detail/push_options.hpp" 21 | 22 | namespace asio { 23 | 24 | inline system_context::executor_type 25 | system_context::get_executor() noexcept 26 | { 27 | return system_executor(); 28 | } 29 | 30 | } // namespace asio 31 | 32 | #include "asio/detail/pop_options.hpp" 33 | 34 | #endif // ASIO_IMPL_SYSTEM_CONTEXT_HPP 35 | -------------------------------------------------------------------------------- /asio/src/tests/unit/high_resolution_timer.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // high_resolution_timer.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | // Disable autolinking for unit tests. 12 | #if !defined(BOOST_ALL_NO_LIB) 13 | #define BOOST_ALL_NO_LIB 1 14 | #endif // !defined(BOOST_ALL_NO_LIB) 15 | 16 | // Prevent link dependency on the Boost.System library. 17 | #if !defined(BOOST_SYSTEM_NO_DEPRECATED) 18 | #define BOOST_SYSTEM_NO_DEPRECATED 19 | #endif // !defined(BOOST_SYSTEM_NO_DEPRECATED) 20 | 21 | // Test that header file is self-contained. 22 | #include "asio/high_resolution_timer.hpp" 23 | 24 | #include "unit_test.hpp" 25 | 26 | ASIO_TEST_SUITE 27 | ( 28 | "high_resolution_timer", 29 | ASIO_TEST_CASE(null_test) 30 | ) 31 | -------------------------------------------------------------------------------- /asio/include/asio/detail/regex_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // detail/regex_fwd.hpp 3 | // ~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_DETAIL_REGEX_FWD_HPP 12 | #define ASIO_DETAIL_REGEX_FWD_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #if defined(ASIO_HAS_BOOST_REGEX) 19 | 20 | namespace boost { 21 | 22 | template 23 | struct sub_match; 24 | 25 | template 26 | class match_results; 27 | 28 | template 29 | class basic_regex; 30 | 31 | } // namespace boost 32 | 33 | #endif // defined(ASIO_HAS_BOOST_REGEX) 34 | 35 | #endif // ASIO_DETAIL_REGEX_FWD_HPP 36 | -------------------------------------------------------------------------------- /asio/src/examples/cpp11/http/server/connection_manager.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // connection_manager.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "connection_manager.hpp" 12 | 13 | namespace http { 14 | namespace server { 15 | 16 | connection_manager::connection_manager() 17 | { 18 | } 19 | 20 | void connection_manager::start(connection_ptr c) 21 | { 22 | connections_.insert(c); 23 | c->start(); 24 | } 25 | 26 | void connection_manager::stop(connection_ptr c) 27 | { 28 | connections_.erase(c); 29 | c->stop(); 30 | } 31 | 32 | void connection_manager::stop_all() 33 | { 34 | for (auto c: connections_) 35 | c->stop(); 36 | connections_.clear(); 37 | } 38 | 39 | } // namespace server 40 | } // namespace http 41 | -------------------------------------------------------------------------------- /asio/include/asio/experimental/co_composed.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // experimental/co_composed.hpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_EXPERIMENTAL_CO_COMPOSED_HPP 12 | #define ASIO_EXPERIMENTAL_CO_COMPOSED_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/detail/config.hpp" 19 | #include "asio/co_composed.hpp" 20 | 21 | #include "asio/detail/push_options.hpp" 22 | 23 | namespace asio { 24 | namespace experimental { 25 | 26 | using asio::co_composed; 27 | 28 | } // namespace experimental 29 | } // namespace asio 30 | 31 | #include "asio/detail/pop_options.hpp" 32 | 33 | #endif // ASIO_EXPERIMENTAL_CO_COMPOSED_HPP 34 | -------------------------------------------------------------------------------- /asio/src/tests/properties/cpp03/can_require_concept_unsupported.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // cpp03/can_require_concept_unsupported.cpp 3 | // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 | #include "asio/require_concept.hpp" 12 | #include 13 | 14 | template 15 | struct prop 16 | { 17 | }; 18 | 19 | template 20 | struct object 21 | { 22 | }; 23 | 24 | namespace asio { 25 | 26 | template 27 | struct is_applicable_property, prop > 28 | { 29 | static const bool value = true; 30 | }; 31 | 32 | } // namespace asio 33 | 34 | int main() 35 | { 36 | assert((!asio::can_require_concept, prop<2> >::value)); 37 | assert((!asio::can_require_concept, prop<2> >::value)); 38 | } 39 | -------------------------------------------------------------------------------- /asio/include/asio/associator.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // associator.hpp 3 | // ~~~~~~~~~~~~~~ 4 | // 5 | // Copyright (c) 2003-2025 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 ASIO_ASSOCIATOR_HPP 12 | #define ASIO_ASSOCIATOR_HPP 13 | 14 | #if defined(_MSC_VER) && (_MSC_VER >= 1200) 15 | # pragma once 16 | #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 17 | 18 | #include "asio/detail/config.hpp" 19 | 20 | #include "asio/detail/push_options.hpp" 21 | 22 | namespace asio { 23 | 24 | /// Used to generically specialise associators for a type. 25 | template