Claudenw commented on code in PR #311:
URL: https://github.com/apache/creadur-rat/pull/311#discussion_r1805037570


##########
apache-rat-core/src/main/java/org/apache/rat/config/exclusion/StandardCollection.java:
##########
@@ -0,0 +1,306 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.rat.config.exclusion;
+
+import java.io.File;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+import java.util.function.Supplier;
+
+import org.apache.rat.config.exclusion.fileProcessors.BazaarIgnoreProcessor;
+import org.apache.rat.config.exclusion.fileProcessors.CVSFileProcessor;
+import org.apache.rat.config.exclusion.fileProcessors.GitFileProcessor;
+import org.apache.rat.config.exclusion.fileProcessors.HgIgnoreProcessor;
+import org.apache.rat.document.impl.DocumentNameMatcherSupplier;
+import org.apache.rat.document.impl.TraceableDocumentNameMatcher;
+import org.apache.rat.utils.iterator.ExtendedIterator;
+import org.apache.rat.utils.iterator.WrappedIterator;
+
+public enum StandardCollection {
+    /**
+     * All of the standard excludes combined
+     */
+    ALL("All of the Standard Excludes combined.", null, null, null),
+    /**
+     * The files and directories created by an ARCH source code control based 
tool.
+     */
+    ARCH("The files and directories created by an ARCH source code control 
based tool.",
+            Collections.singletonList("**/.arch-ids/**"), null, null),
+    /**
+     * The files and directories created by a Bazaar source code control based 
tool.
+     */
+    BAZAAR("The files and directories created by a Bazaar source code control 
based tool.",
+            Arrays.asList("**/.bzr/**", ".bzrignore"), null, new 
BazaarIgnoreProcessor()),
+    /**
+     * The files and directories created by a Bitkeeper source code control 
based tool.
+     */
+    BITKEEPER("The files and directories created by a Bitkeeper source code 
control based tool.",
+            Arrays.asList("**/BitKeeper/**", "**/ChangeSet/**"), null, null),
+    /**
+     * The files and directories created by a CVS source code control based 
tool.
+     */
+    CVS("The files and directories created by a CVS source code control based 
tool.",
+            Arrays.asList("**/.cvsignore",
+                    "**/RCS/**", "**/SCCS/**", "**/CVS/**", "**/CVS.adm/**",
+                    "**/RCSLOG/**", "**/cvslog.*", "**/tags/**", "**/TAGS/**",
+                    "**/.make.state", "**/.nse_depinfo",
+                    "**/*~", "**/#*", "**/.#*", "**/,*", "**/_$*", "**/*$", 
"**/*.old", "**/*.bak", "**/*.BAK",
+                    "**/*.orig", "**/*.rej", "**/.del-*",
+                    "**/*.a", "**/*.old", "**/*.o", "**/*.obj", "**/*.so", 
"**/*.exe",
+                    "**/*.Z", "**/*.elc", "**/*.ln", "**/core"),
+            null, new CVSFileProcessor()),
+    /**
+     * The files and directories created by a DARCS source code control based 
tool.
+     */
+    DARCS("The files and directories created by a DARCS source code control 
based tool.",
+            Arrays.asList("**/_darcs/**", "**/.darcsrepo/**", 
"**/-darcs-backup*", "**/.darcs-temp-mail"), null, null),
+    /**
+     * The files and directories created by an Eclipse IDE based tool.
+     */
+    ECLIPSE("The files and directories created by an Eclipse IDE based tool.",
+            Arrays.asList(".checkstyle", ".classpath", ".factorypath", 
".project", ".settings/**"),
+            null, null),
+    /**
+     * The files and directories created by GIT source code control to support 
GIT, also processes files listed in '.gitignore'.
+     */
+    GIT("The files and directories created by GIT source code control to 
support GIT, also processes files listed in '.gitignore'.",
+            Arrays.asList("**/.git/**", "**/.gitignore"),
+            null,
+            new GitFileProcessor()
+    ),
+    /**
+     * The hidden directories. Directories with names that start with '.'
+     */
+    HIDDEN_DIR("The hidden directories. Directories with names that start with 
'.'",
+            null,
+            str -> TraceableDocumentNameMatcher.make(() -> "HIDDEN_DIR", 
documentName -> {
+                File f = new File(documentName.name());
+                return f.isDirectory() && ExclusionUtils.isHidden(f);
+            }), null
+    ),
+    /**
+     * The hidden files. Directories with names that start with '.'
+     */
+    HIDDEN_FILE("The hidden files. Directories with names that start with '.'",
+            null,
+            str -> TraceableDocumentNameMatcher.make(() -> "HIDDEN_FILE", 
documentName -> {
+                File f = new File(documentName.name());
+                return f.isFile() && ExclusionUtils.isHidden(f);
+            }), null
+    ),
+    /**
+     * The files and directories created by an IDEA IDE based tool.
+     */
+    IDEA("The files and directories created by an IDEA IDE based tool.",
+            Arrays.asList(
+                    "*.iml",
+                    "*.ipr",
+                    "*.iws",
+                    ".idea/**"), null, null),
+    /**
+     * The .DS_Store files MAC computer.
+     */
+    MAC("The .DS_Store files MAC computer.",
+            Collections.singletonList("**/.DS_Store"), null, null),
+    /**
+     * The files and directories created by Maven build system based project.
+     */
+    MAVEN("The files and directories created by Maven build system based 
project.",
+            Arrays.asList(//
+                    "target/**", //
+                    "cobertura.ser", //
+                    "**/MANIFEST.MF", // a MANIFEST.MF file cannot contain 
comment lines. In other words: It is not possible, to include a license.
+                    "release.properties", //
+                    ".repository", // Used by Jenkins when a Maven job uses a 
private repository that is "Local to the workspace"
+                    "build.log", // RAT-160: until now maven-invoker-plugin 
runs create a build.log that is not part of a release
+                    ".mvn/**", // Project configuration since Maven 3.3.1 
which contains maven.config, jvm.config, extensions.xml
+                    "pom.xml.releaseBackup"), null, null),
+    /**
+     * The files and directories created by a Mercurial source code control 
based tool.
+     */
+    MERCURIAL("The files and directories created by a Mercurial source code 
control based tool.",
+            Arrays.asList("**/.hg/**", ".hgignore"), null, new 
HgIgnoreProcessor()),
+    /**
+     * The set of miscellaneous files generally left by editors and the like.
+     */
+    MISC("The set of miscellaneous files generally left by editors and the 
like.",
+            Arrays.asList("**/*~", "**/#*#", "**/.#*", "**/%*%", "**/._*"),
+            null, null),
+    /**
+     * The files and directories created by an MKS source code control based 
tool.
+     */
+    MKS("The files and directories created by an MKS source code control based 
tool.",
+            Collections.singletonList("**/project.pj"), null, null),
+    /**
+     * The files and directories created by a RCS source code control based 
tool.
+     */
+    RCS("The files and directories created by a RCS source code control based 
tool.",
+            Collections.singletonList("**/RCS/**"), null, null),
+    /**
+     * The files and directories created by a SCCS source code control based 
tool.
+     */
+    SCCS("The files and directories created by a SCCS source code control 
based tool.",
+            Collections.singletonList("**/SCCS/**"), null, null),
+    /**
+     * The files and directories created by a Serena Dimensions V10 change 
control system based tool.
+     */
+    SERENA_DIMENSIONS_10("The files and directories created by a Serena 
Dimensions V10 change control system based tool.",
+            Collections.singletonList("**/.metadata/**"), null, null),
+    /**
+     * A standard collection of generally accepted patterns to ignore.
+     */
+    STANDARD_PATTERNS("A standard collection of generally accepted patterns to 
ignore.", null, null, null),
+    /**
+     * A standard collection of SCMs
+     */
+    STANDARD_SCMS("A standard collection of SCMs", null, null, null),

Review Comment:
   added java comment -- not javadoc.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@creadur.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to