public class SafeServiceLoader extends Object
META-INF/services using a given class loader,
avoiding the system class loader used by java.util.ServiceLoader.| Constructor and Description |
|---|
SafeServiceLoader(ClassLoader classLoader)
Constructs a service loader using the given class loader.
|
public SafeServiceLoader(ClassLoader classLoader)
classLoader - public <T> List<T> load(String serviceType)
A class that cannot be loaded by the class loader passed to the constructor of this class is silently ignored.
serviceType - fully qualified service class nameNoServiceProviderException - if a resource cannot be read or if a loaded class cannot
be instantiatedCopyright © 2006-2014 OPS4J - Open Participation Software for Java. All Rights Reserved.