Package org.apache.any23.extractor
Interface ExtractionResult
-
- All Superinterfaces:
IssueReport
- All Known Subinterfaces:
TagSoupExtractionResult
- All Known Implementing Classes:
ExtractionResultImpl
public interface ExtractionResult extends IssueReport
Interface defining the methods that a representation of an extraction result must have.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.apache.any23.extractor.IssueReport
IssueReport.Issue, IssueReport.IssueLevel
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
close()
Close the result.ExtractionResult
openSubResult(ExtractionContext extractionContext)
Open a result nested in the current one.void
writeNamespace(String prefix, String IRI)
Write a namespace.void
writeTriple(org.eclipse.rdf4j.model.Resource s, org.eclipse.rdf4j.model.IRI p, org.eclipse.rdf4j.model.Value o)
Write a triple.void
writeTriple(org.eclipse.rdf4j.model.Resource s, org.eclipse.rdf4j.model.IRI p, org.eclipse.rdf4j.model.Value o, org.eclipse.rdf4j.model.IRI g)
Writes a triple.-
Methods inherited from interface org.apache.any23.extractor.IssueReport
getIssues, notifyIssue, printReport
-
-
-
-
Method Detail
-
writeTriple
void writeTriple(org.eclipse.rdf4j.model.Resource s, org.eclipse.rdf4j.model.IRI p, org.eclipse.rdf4j.model.Value o, org.eclipse.rdf4j.model.IRI g)
Writes a triple. Parameters can be null, then the triple will be silently ignored.- Parameters:
s
- subjectp
- predicateo
- objectg
- graph
-
writeTriple
void writeTriple(org.eclipse.rdf4j.model.Resource s, org.eclipse.rdf4j.model.IRI p, org.eclipse.rdf4j.model.Value o)
Write a triple. Parameters can be null, then the triple will be silently ignored.- Parameters:
s
- subjectp
- predicateo
- object
-
writeNamespace
void writeNamespace(String prefix, String IRI)
Write a namespace.- Parameters:
prefix
- the prefix of the namespaceIRI
- the long IRI identifying the namespace
-
close
void close()
Close the result.
Extractors should close their results as soon as possible, but don't have to, the environment will close any remaining ones. Implementations should be robust against multiple close() invocations.
-
openSubResult
ExtractionResult openSubResult(ExtractionContext extractionContext)
Open a result nested in the current one.- Parameters:
extractionContext
- the context to be used to open the sub result.- Returns:
- the instance of the nested extraction result.
-
-