Ignore:
Timestamp:
2017-06-11T13:39:33+02:00 (7 years ago)
Author:
michael2402
Message:

See #14794: Document data.validation package and subpackages.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/validation/OsmValidator.java

    r12282 r12390  
    134134    };
    135135
     136    /**
     137     * Adds a test to the list of available tests
     138     * @param testClass The test class
     139     */
    136140    public static void addTest(Class<? extends Test> testClass) {
    137141        allTests.add(testClass);
     
    193197    }
    194198
     199    /**
     200     * Adds an ignored error
     201     * @param s The ignore group / sub group name
     202     * @see TestError#getIgnoreGroup()
     203     * @see TestError#getIgnoreSubGroup()
     204     */
    195205    public static void addIgnoredError(String s) {
    196206        ignoredErrors.add(s);
    197207    }
    198208
     209    /**
     210     * Check if a error should be ignored
     211     * @param s The ignore group / sub group name
     212     * @return <code>true</code> to ignore that error
     213     */
    199214    public static boolean hasIgnoredError(String s) {
    200215        return ignoredErrors.contains(s);
    201216    }
    202217
     218    /**
     219     * Saves the names of the ignored errors to a file
     220     */
    203221    public static void saveIgnoredErrors() {
    204222        try (PrintWriter out = new PrintWriter(new File(getValidatorDir(), "ignorederrors"), StandardCharsets.UTF_8.name())) {
     
    270288    }
    271289
     290    /**
     291     * Gets all tests that are possible
     292     * @return The tests
     293     */
    272294    public static Collection<Test> getTests() {
    273295        return getAllTestsMap().values();
    274296    }
    275297
     298    /**
     299     * Gets all tests that are run
     300     * @param beforeUpload To get the ones that are run before upload
     301     * @return The tests
     302     */
    276303    public static Collection<Test> getEnabledTests(boolean beforeUpload) {
    277304        Collection<Test> enabledTests = getTests();
Note: See TracChangeset for help on using the changeset viewer.