org.apache.qpid.proton
Class ProtonFactoryLoader<C extends ProtonFactory>
java.lang.Object
org.apache.qpid.proton.ProtonFactoryLoader<C>
public class ProtonFactoryLoader<C extends ProtonFactory>
- extends Object
A thin wrapper around ServiceLoader intended for loading Proton object factories.
If system property "qpid.proton.implementationtype" if set, loads a factory
whose ProtonFactory.ImplementationType matches its value.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
IMPLEMENTATION_TYPE_PROPERTY
public static final String IMPLEMENTATION_TYPE_PROPERTY
- See Also:
- Constant Field Values
ProtonFactoryLoader
public ProtonFactoryLoader()
- Use this constructor if you intend to explicitly provide factory interface later,
i.e. by calling
loadFactory(Class). This is useful if you want to use the same
ProtonFactoryLoader instance for loading multiple factory types.
ProtonFactoryLoader
public ProtonFactoryLoader(Class<C> factoryInterface)
ProtonFactoryLoader
public ProtonFactoryLoader(Class<C> factoryInterface,
ProtonFactory.ImplementationType implementationType)
- Parameters:
factoryInterface - will be used as the factory interface class in calls to loadFactory().
loadFactory
public C loadFactory()
- Returns the Proton factory that implements the stored
_factoryInterface class.
loadFactory
public C loadFactory(Class<C> factoryInterface)
Copyright © 2013 The Apache Software Foundation. All Rights Reserved.