Boost.Corosio

    • Introduction
    • Quick Start
    • Tutorials
      • Echo Server
      • HTTP Client
      • DNS Lookup
      • TLS Context Configuration
    • Guide
      • TCP/IP Networking
      • Concurrent Programming
      • I/O Context
      • Sockets
      • Acceptors
      • Endpoints
      • Composed Operations
      • Timers
      • Signal Handling
      • Name Resolution
      • TCP Server
      • TLS Encryption
      • Error Handling
      • Buffer Sequences
    • Concepts
      • Design Rationale
      • Affine Awaitables
    • Testing
      • Mock Sockets
    • Reference
    • Glossary
  • boost::corosio::tcp_server::bind
arrow_upward

boost::corosio::tcp_server::bind

Bind to a local endpoint.

Synopsis

Declared in <boost/corosio/tcp_server.hpp>

std::error_code
bind(endpoint ep);

Description

Creates an acceptor listening on the specified endpoint. Multiple endpoints can be bound by calling this method multiple times before start.

Return Value

The error code if binding fails.

Parameters

Name Description

ep

The local endpoint to bind to.

Created with MrDocs