rdf_qa/commit

added hook documentation

authorJacco van Ossenbruggen
Fri May 18 13:43:45 2012 +0200
committerJacco van Ossenbruggen
Fri May 18 13:43:45 2012 +0200
commit467cd78f8e998a560976c64615933458156d76f1
tree7bf1cc7039ef4dabf8e02c1fd7f5e768e79d0495
parent96ae2973572312fd5d49f18f32c5a9a67bbeefad
Diff style: patch stat
diff --git a/components/qa_heuristics.pl b/components/qa_heuristics.pl
index 7c5af14..f9cf8b3 100644
--- a/components/qa_heuristics.pl
+++ b/components/qa_heuristics.pl
@@ -1,9 +1,11 @@
-:- module(qa, [
-	       rdf_warning/2,
-	       rdf_qa_ok/2,
-	       class_label//1
-	      ]).
+:- module(qa, []).
 
+/** <module> RDF QA hooks
+
+This module declares the _hooks_ an application  may define to extend or
+modify some of ClioPatria's RDF QA behaviour. Hooks are =multifile=
+defined predicates that may have no default definition.
+*/
 
 :- multifile
 	rdf_warning/2,
@@ -14,3 +16,21 @@
 :- rdf_meta
 	rdf_warning(o,r).
 
+%%	rdf_warning(?ErrorClass, ?URI) is nondet.
+%
+%	True if URI contains an error in class ErrorClass.
+%	Note: qa:rdf_warning is multifile so you can define your own
+%	error classes. If you do, you also need to add class_label//1
+%	for your new class.
+
+%%	rdf_qa_ok(?ErrorClass, ?URI) is nondet.
+%
+%	True if URI should never be reported as being in class
+%	ErrorClass. This multifile predicate allows you to suppress
+%	warnings for certain URIs, for example for URIs that are known
+%	to contain errors that you cannot fix.
+
+%%	class_label(+ErrorClass)// is det.
+%
+%	Writes the error message associated with ErrorClass to HTML.
+