public abstract class Extractor extends Object
Constructor and Description |
---|
Extractor() |
Modifier and Type | Method and Description |
---|---|
protected abstract Iterable<Opinion> |
doExtract(KAFDocument document,
int sentenceID,
EnumSet<Component> components) |
protected void |
doFilter(KAFDocument document) |
protected abstract Iterable<Opinion> |
doRefine(KAFDocument document,
int sentenceID,
EnumSet<Component> components,
Opinion opinion) |
protected void |
doWrite(Properties properties,
Path path) |
void |
extract(Iterable<KAFDocument> documents,
String outLabel,
Component... components) |
void |
extract(KAFDocument document,
String outLabel,
Component... components) |
static void |
main(String... args) |
static Extractor |
readFrom(Path path,
Properties customProperties) |
void |
refine(Iterable<KAFDocument> documents,
Iterable<String> inLabels,
String outLabel,
Component... components) |
void |
refine(KAFDocument document,
Iterable<String> inLabels,
String outLabel,
Component... components) |
void |
writeTo(Path path) |
public final void extract(Iterable<KAFDocument> documents, String outLabel, Component... components)
public final void extract(KAFDocument document, @Nullable String outLabel, Component... components)
public final void refine(Iterable<KAFDocument> documents, @Nullable Iterable<String> inLabels, @Nullable String outLabel, Component... components)
public final void refine(KAFDocument document, @Nullable Iterable<String> inLabels, @Nullable String outLabel, Component... components)
protected void doFilter(KAFDocument document)
protected abstract Iterable<Opinion> doExtract(KAFDocument document, int sentenceID, EnumSet<Component> components)
protected abstract Iterable<Opinion> doRefine(KAFDocument document, int sentenceID, EnumSet<Component> components, Opinion opinion)
protected void doWrite(Properties properties, Path path) throws IOException
IOException
public final void writeTo(Path path) throws IOException
IOException
public static Extractor readFrom(Path path, @Nullable Properties customProperties) throws IOException
IOException
public static void main(String... args)
Copyright © 2016–2020 FBK. All rights reserved.