Package net.ontopia.utils
Class ServiceUtils
java.lang.Object
net.ontopia.utils.ServiceUtils
Utility to load dynamic services from classpath.
- Since:
- 5.4.0
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic <T> Set<T>loadServices(Class<T> clazz) Calls#loadServices(java.lang.Class, java.lang.String)with resource as the default location: META-INF/services/[classname].
-
Field Details
-
SERVICES_ROOT
- See Also:
-
-
Constructor Details
-
ServiceUtils
public ServiceUtils()
-
-
Method Details
-
loadServices
Calls#loadServices(java.lang.Class, java.lang.String)with resource as the default location: META-INF/services/[classname].- Type Parameters:
T- The type of the services to load- Parameters:
clazz- The class that the services have to implement- Returns:
- The service instances found on the classpath
- Throws:
IOException
-