01: /*
02: * Created on 18-Jun-2004
03: *
04: * TODO To change the template for this generated file go to
05: * Window - Preferences - Java - Code Generation - Code and Comments
06: */
07: package org.geotools.validation.relate;
08:
09: import java.util.ArrayList;
10: import java.util.List;
11:
12: import org.geotools.feature.Feature;
13: import org.geotools.validation.Validation;
14: import org.geotools.validation.ValidationResults;
15:
16: /**
17: * @source $URL: http://svn.geotools.org/geotools/tags/2.4.1/modules/extension/validation/src/main/java/org/geotools/validation/relate/TempFeatureResults.java $
18: */
19: final class TempFeatureResults implements ValidationResults {
20: Validation trial;
21: List error = new ArrayList();
22: List warning = new ArrayList();
23:
24: public void setValidation(Validation validation) {
25: trial = validation;
26: }
27:
28: public void error(Feature feature, String message) {
29: String where = feature != null ? feature.getID() : "all";
30: error.add(where + ":" + message);
31: System.err.println(where + ":" + message);
32: }
33:
34: public void warning(Feature feature, String message) {
35: String where = feature != null ? feature.getID() : "all";
36: warning.add(where + ":" + message);
37: System.out.println(where + ":" + message);
38: }
39: }
|