1 | package org.greenstone.gsdl3.gs3build.classifier;
|
---|
2 |
|
---|
3 | import java.util.List;
|
---|
4 |
|
---|
5 | import org.w3c.dom.Element;
|
---|
6 | import org.greenstone.gsdl3.gs3build.doctypes.DocumentID;
|
---|
7 | import org.greenstone.gsdl3.gs3build.doctypes.DocumentInterface;
|
---|
8 |
|
---|
9 | public interface ClassifierInterface
|
---|
10 | {
|
---|
11 | /**
|
---|
12 | * Initialise the classifier as required. The parameters given are specific
|
---|
13 | * to the classifier type, so this interface does not guarantee any interpretations
|
---|
14 | * of any given parameter.
|
---|
15 | *
|
---|
16 | * @param <code>List</code> the parameters with which to configure the classifier.
|
---|
17 | */
|
---|
18 | public void configure(List parameters);
|
---|
19 | public void configure(java.net.URL baseURL, org.w3c.dom.Node node);
|
---|
20 |
|
---|
21 | public void setDatabase(org.greenstone.gsdl3.gs3build.util.GS3SQLConnection connection);
|
---|
22 |
|
---|
23 | /**
|
---|
24 | * Classify an individual document - the document should be informed of any
|
---|
25 | * classification nodes which it is assigned to, so that it can obtain knowledge
|
---|
26 | * of any "parents". These are assigned into the "classified" metadata item in
|
---|
27 | * the "gsdl3" namespace...
|
---|
28 | */
|
---|
29 | public boolean classifyDocument(DocumentID documentID, DocumentInterface document);
|
---|
30 |
|
---|
31 | public void startClassifierPass(int pass);
|
---|
32 |
|
---|
33 | public int getClassifierPasses();
|
---|
34 |
|
---|
35 | public void endClassifierPass(int pass);
|
---|
36 |
|
---|
37 | /**
|
---|
38 | * Called at the end of the classification sequence - the classifier should
|
---|
39 | * save its state at this point...
|
---|
40 | */
|
---|
41 | public void completeClassification();
|
---|
42 |
|
---|
43 | public boolean addClassifierDescription(Element classifier_list);
|
---|
44 | }
|
---|