Poco::Net

class TCPServerConnectionFactory

File Information

Library: Net
Package: TCPServer
Header: Poco/Net/TCPServerConnectionFactory.h

Description

A factory for TCPServerConnection objects.

The TCPServer class uses a TCPServerConnectionFactory to create a connection object for each new connection it accepts.

Subclasses must override the createConnection() method.

The TCPServerConnectionFactoryImpl template class can be used to automatically instantiate a TCPServerConnectionFactory for a given subclass of TCPServerConnection.

Inheritance

Known Derived Classes: HTTPServerConnectionFactory, TCPServerConnectionFactoryImpl, Poco::OSP::Shell::ShellConnectionFactory, Poco::RemotingNG::TCP::ServerConnectionFactory

Member Summary

Member Functions: createConnection

Types Aliases

Ptr

using Ptr = Poco::SharedPtr < TCPServerConnectionFactory >;

Constructors

TCPServerConnectionFactory protected

TCPServerConnectionFactory();

Destructor

~TCPServerConnectionFactory virtual

virtual ~TCPServerConnectionFactory();

Member Functions

createConnection virtual

virtual TCPServerConnection * createConnection(
    const StreamSocket & socket
) = 0;

Creates an instance of a subclass of TCPServerConnection, using the given StreamSocket.