File Information
Library: RemotingNG
Package: Transport
Header: Poco/RemotingNG/TransportFactoryManager.h
Description
A TransportFactoryManager manages TransportFactory objects.
Member Summary
Member Functions: createTransport, hasFactory, instance, registerFactory, unregisterFactory
Constructors
Destructor
~TransportFactoryManager
Destroys the TransportFactoryManager.
Member Functions
createTransport
Transport * createTransport(
const std::string & protocol
);
Creates a new Transport for the given protocol.
The newly created Transport is unconnected.
Throws an exception if the protocol is unknown
createTransport
Transport * createTransport(
const std::string & protocol,
const std::string & uri
);
Creates a new Transport for the given protocol and connects it to the endpoint specified by the given URI.
Throws an exception if the protocol is unknown.
hasFactory
bool hasFactory(
const std::string & protocol
) const;
Returns true if for the protocol a factory was registered.
instance
static TransportFactoryManager & instance();
Returns a reference to the one and only instance of TransportFactoryManager.
registerFactory
void registerFactory(
const std::string & protocol,
TransportFactory::Ptr pFactory
);
Registers the factory if it doesn't exist yet.
unregisterFactory
void unregisterFactory(
const std::string & protocol
);
Removes the factory from the manager. If for the given protocol no factory is found, the error is silently ignored.