class ExclusionArtifactFilter implements ArtifactFilter {

    private final List<Exclusion> exclusions;
    private final List<Predicate<Artifact>> predicates;

    public ExclusionArtifactFilter(List<Exclusion> exclusions) {
        this.exclusions = exclusions;
        this.predicates =
                exclusions.stream().map(ExclusionArtifactFilter::toPredicate).collect(Collectors.toList());
    }

    @Override
    public boolean include(Artifact artifact) {
        return predicates.stream().noneMatch(p -> p.test(artifact));
    }

    private static Predicate<Artifact> toPredicate(Exclusion exclusion) {
        PathMatcher groupId = FileSystems.getDefault().getPathMatcher("glob:" + exclusion.getGroupId());
        PathMatcher artifactId = FileSystems.getDefault().getPathMatcher("glob:" + exclusion.getArtifactId());
        Predicate<Artifact> predGroupId = a -> groupId.matches(createPathProxy(a.getGroupId()));
        Predicate<Artifact> predArtifactId = a -> artifactId.matches(createPathProxy(a.getArtifactId()));
        return predGroupId.and(predArtifactId);
    }

    /**
     * In order to reuse the glob matcher from the filesystem, we need
     * to create Path instances.  Those are only used with the toString method.
     * This hack works because the only system-dependent thing is the path
     * separator which should not be part of the groupId or artifactId.
     */
    private static Path createPathProxy(String value) {<FILL_FUNCTION_BODY>}
}

        return (Path) Proxy.newProxyInstance(
                ExclusionArtifactFilter.class.getClassLoader(), new Class[] {Path.class}, (proxy1, method, args) -> {
                    if ("toString".equals(method.getName())) {
                        return value;
                    }
                    throw new UnsupportedOperationException();
                });
    
<no_super_class>