@Test public void testIsProviderInterface() { assertEquals(true, Providers.isProvider(Provider.class)); assertEquals(false, Providers.isProvider(NotProvider.class)); assertEquals(true, Providers.isProvider(JaxRsProvider.class)); assertEquals(true, Providers.isProvider(ClassBasedProvider.class)); }
public static boolean isProvider(final Class<?> clazz) { return findFirstProviderContract(clazz); }
Providers { public static boolean isProvider(final Class<?> clazz) { return findFirstProviderContract(clazz); } }
Providers { public static boolean isProvider(final Class<?> clazz) { return findFirstProviderContract(clazz); } private  Providers(); }
Providers { public static boolean isProvider(final Class<?> clazz) { return findFirstProviderContract(clazz); } private  Providers(); static Set<T> getProviders(InjectionManager injectionManager, Class<T> contract); static Set<T> getCustomProviders(InjectionManager injectionManager, Class<T> contract); static Iterable<T> getAllProviders(InjectionManager injectionManager, Class<T> contract); static Iterable<RankedProvider<T>> getAllRankedProviders(InjectionManager injectionManager, Class<T> contract); @SuppressWarnings("TypeMayBeWeakened") static Iterable<T> sortRankedProviders(final RankedComparator<T> comparator,
                                                      final Iterable<RankedProvider<T>> providers); @SuppressWarnings("TypeMayBeWeakened") static Iterable<T> getAllRankedSortedProviders(InjectionManager injectionManager, Class<T> contract); @SuppressWarnings("TypeMayBeWeakened") static Iterable<T> mergeAndSortRankedProviders(final RankedComparator<T> comparator,
                                                              final Iterable<Iterable<RankedProvider<T>>> providerIterables); static Iterable<T> getAllProviders(
            InjectionManager injectionManager, Class<T> contract, RankedComparator<T> comparator); static Collection<ServiceHolder<T>> getAllServiceHolders(InjectionManager injectionManager, Class<T> contract); static boolean isJaxRsProvider(final Class<?> clazz); static Iterable<T> getAllProviders(
            InjectionManager injectionManager, Class<T> contract, Comparator<T> comparator); static Set<Class<?>> getProviderContracts(final Class<?> clazz); static boolean checkProviderRuntime(final Class<?> component,
                                               final ContractProvider model,
                                               final RuntimeType runtimeConstraint,
                                               final boolean scanned,
                                               final boolean isResource); static boolean isSupportedContract(final Class<?> type); static boolean isProvider(final Class<?> clazz); static void ensureContract(final Class<?> contract, final Class<?>... implementations); }
Providers { public static boolean isProvider(final Class<?> clazz) { return findFirstProviderContract(clazz); } private  Providers(); static Set<T> getProviders(InjectionManager injectionManager, Class<T> contract); static Set<T> getCustomProviders(InjectionManager injectionManager, Class<T> contract); static Iterable<T> getAllProviders(InjectionManager injectionManager, Class<T> contract); static Iterable<RankedProvider<T>> getAllRankedProviders(InjectionManager injectionManager, Class<T> contract); @SuppressWarnings("TypeMayBeWeakened") static Iterable<T> sortRankedProviders(final RankedComparator<T> comparator,
                                                      final Iterable<RankedProvider<T>> providers); @SuppressWarnings("TypeMayBeWeakened") static Iterable<T> getAllRankedSortedProviders(InjectionManager injectionManager, Class<T> contract); @SuppressWarnings("TypeMayBeWeakened") static Iterable<T> mergeAndSortRankedProviders(final RankedComparator<T> comparator,
                                                              final Iterable<Iterable<RankedProvider<T>>> providerIterables); static Iterable<T> getAllProviders(
            InjectionManager injectionManager, Class<T> contract, RankedComparator<T> comparator); static Collection<ServiceHolder<T>> getAllServiceHolders(InjectionManager injectionManager, Class<T> contract); static boolean isJaxRsProvider(final Class<?> clazz); static Iterable<T> getAllProviders(
            InjectionManager injectionManager, Class<T> contract, Comparator<T> comparator); static Set<Class<?>> getProviderContracts(final Class<?> clazz); static boolean checkProviderRuntime(final Class<?> component,
                                               final ContractProvider model,
                                               final RuntimeType runtimeConstraint,
                                               final boolean scanned,
                                               final boolean isResource); static boolean isSupportedContract(final Class<?> type); static boolean isProvider(final Class<?> clazz); static void ensureContract(final Class<?> contract, final Class<?>... implementations);  }