@Override
    public <T> Iterator<Class<T>> createClassIterator(
        final Class<T> service,
        final String serviceName,
        final ClassLoader loader,
        final boolean ignoreOnClassNotFound
    )
    {
        final Iterator<Class<T>> delegateClassIterator = delegate.createClassIterator(
            service, serviceName, loader, ignoreOnClassNotFound);

        Stream<Class<T>> stream = StreamSupport.stream(
            Spliterators.spliteratorUnknownSize(delegateClassIterator, Spliterator.ORDERED), false);

        return stream.filter(t -> !t.getPackage().getName().startsWith("com.sun.jersey")).collect(Collectors.toList()).iterator();
    }
@Override
    public <T> Iterator<Class<T>> createClassIterator(
        final Class<T> service,
        final String serviceName,
        final ClassLoader loader,
        final boolean ignoreOnClassNotFound
    )
    {
        final Iterator<Class<T>> delegateClassIterator = delegate.createClassIterator(
            service, serviceName, loader, ignoreOnClassNotFound);

        Stream<Class<T>> stream = StreamSupport.stream(
            Spliterators.spliteratorUnknownSize(delegateClassIterator, Spliterator.ORDERED), false);

        return stream.filter(t -> !t.getPackage().getName().startsWith("com.sun.jersey")).collect(Collectors.toList()).iterator();
    }
@ Override public < T > Iterator < Class < T > > createClassIterator ( final Class < T > service , final String serviceName , final ClassLoader loader , final boolean ignoreOnClassNotFound ) { final Iterator < Class < T > > delegateClassIterator = delegate . createClassIterator ( service , serviceName , loader , ignoreOnClassNotFound ) ; Stream < Class < T > > stream = StreamSupport . stream ( Spliterators . spliteratorUnknownSize ( delegateClassIterator , Spliterator . ORDERED ) , false ) ; return stream . filter ( t -> ! t . getPackage ( ) . getName ( ) . startsWith ( "com.sun.jersey" ) ) . collect ( Collectors . toList ( ) ) . iterator ( ) ; }
Excludes all "com.sun.jersey" classes.
Excludes all com . sun . jersey classes .