Registry of all Transport Factories that are available to the client at runtime.
More...
#include <src/main/activemq/transport/TransportRegistry.h>
Registry of all Transport Factories that are available to the client at runtime.
New Transport's must have a factory registered here before a connection attempt is made.
- Since
- 3.0
◆ ~TransportRegistry()
virtual activemq::transport::TransportRegistry::~TransportRegistry |
( |
| ) |
|
|
virtual |
◆ findFactory()
Gets a Registered TransportFactory from the Registry and returns it if there is not a registered format factory with the given name an exception is thrown.
- Parameters
-
name | The name of the Factory to find in the Registry. |
- Returns
- the Factory registered under the given name.
- Exceptions
-
NoSuchElementException | if no factory is registered with that name. |
◆ getInstance()
Gets the single instance of the TransportRegistry.
- Returns
- reference to the single instance of this Registry
◆ getTransportNames()
std::vector< std::string > activemq::transport::TransportRegistry::getTransportNames |
( |
| ) |
const |
Retrieves a list of the names of all the Registered Transport's in this Registry.
- Returns
- stl vector of strings with all the Transport names registered.
◆ registerFactory()
void activemq::transport::TransportRegistry::registerFactory |
( |
const std::string & | name, |
|
|
TransportFactory * | factory ) |
Registers a new TransportFactory with this Registry.
If a Factory with the given name is already registered it is overwritten with the new one. Once a factory is added to the Registry its lifetime is controlled by the Registry, it will be deleted once the Registry has been deleted.
- Parameters
-
name | The name of the new Factory to register. |
factory | The new Factory to add to the Registry. |
- Exceptions
-
IllegalArgumentException | is name is the empty string. |
NullPointerException | if the Factory is Null. |
◆ unregisterAllFactories()
void activemq::transport::TransportRegistry::unregisterAllFactories |
( |
| ) |
|
Removes all Factories and deletes the instances of the Factory objects.
◆ unregisterFactory()
void activemq::transport::TransportRegistry::unregisterFactory |
( |
const std::string & | name | ) |
|
Unregisters the Factory with the given name and deletes that instance of the Factory.
- Parameters
-
name | Name of the Factory to unregister and destroy |
◆ activemq::library::ActiveMQCPP
The documentation for this class was generated from the following file: