Package org.linkki.util.service
Class Services
- java.lang.Object
-
- org.linkki.util.service.Services
-
public final class Services extends Object
Helper forServiceLoaderaccess.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static <S> Sget(Class<S> serviceClass)Finds the single implementation of the service class viaServiceLoader.
-
-
-
Method Detail
-
get
public static <S> S get(Class<S> serviceClass)
Finds the single implementation of the service class viaServiceLoader.- Returns:
- the service instance
- Throws:
IllegalStateException- if there is no or more than one implementation available
-
-