@SuppressWarnings("unchecked")
   private <T> T loadService(Class<T> spiType, Class<?> defaultImpl, ClassLoader loader)
   {
      final String defaultImplName = defaultImpl != null ? defaultImpl.getName() : null;
      return (T)ServiceLoader.loadService(spiType.getName(), defaultImplName, loader);
   }
@ SuppressWarnings ( "unchecked" ) private < T > T loadService ( Class < T > spiType , Class < ? > defaultImpl , ClassLoader loader ) { final String defaultImplName = defaultImpl != null ? defaultImpl . getName ( ) : null ; return ( T ) ServiceLoader . loadService ( spiType . getName ( ) , defaultImplName , loader ) ; }
Load SPI implementation through ServiceLoader