private static String serviceName(Class<?> serviceInterface) {
    // Service name
    Service serviceAnnotation = serviceInterface.getAnnotation(Service.class);
    requireNonNull(
        serviceAnnotation != null, String.format("Not a service interface: %s", serviceInterface));
    return isNullOrEmpty(serviceAnnotation.value())
        ? serviceInterface.getName()
        : serviceAnnotation.value();
  }
private static String serviceName ( Class < ? > serviceInterface ) { Service serviceAnnotation = serviceInterface . getAnnotation ( Service . class ) ; requireNonNull ( serviceAnnotation != null , String . format ( "Not a service interface: %s" , serviceInterface ) ) ; return isNullOrEmpty ( serviceAnnotation . value ( ) ) ? serviceInterface . getName ( ) : serviceAnnotation . value ( ) ; }
Util function to extract service name from service api.

@param serviceInterface with @Service annotation.
@return service name.