Package org.obolibrary.robot
Class Template
- java.lang.Object
-
- org.obolibrary.robot.Template
-
public class Template extends Object
- Author:
- Becky Tauber
-
-
Constructor Summary
Constructors Constructor Description Template(String name, List<List<String>> rows)
Given a template name and a list of rows, create a template object with a new IOHelper and QuotedEntityChecker.Template(String name, List<List<String>> rows, IOHelper ioHelper)
Given a template name, a list of rows, and an IOHelper, create a template object with a new QuotedEntityChecker.Template(String name, List<List<String>> rows, org.semanticweb.owlapi.model.OWLOntology inputOntology)
Given a template name, a list of rows, and an input ontology, create a template object with a new IOHelper and QuotedEntityChecker populated by the input ontology.Template(String name, List<List<String>> rows, org.semanticweb.owlapi.model.OWLOntology inputOntology, IOHelper ioHelper)
Given a template name, a list of rows, an input ontology, and an IOHelper, create a template object with a new QuotedEntityChecker with the IOHelper populated by the input ontology.Template(String name, List<List<String>> rows, org.semanticweb.owlapi.model.OWLOntology inputOntology, IOHelper ioHelper, QuotedEntityChecker checker)
Given a template name, a list of rows, an IOHelper, and a QuotedEntityChecker, create a template object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.semanticweb.owlapi.model.OWLOntology
generateOutputOntology()
Generate an OWLOntology based on the rows of the template.org.semanticweb.owlapi.model.OWLOntology
generateOutputOntology(String outputIRI, boolean force)
Generate an OWLOntology based on the rows of the template.org.semanticweb.owlapi.model.OWLOntology
generateOutputOntology(String outputIRI, boolean force, String errorsPath)
Generate an OWLOntology with given IRI based on the rows of the template.QuotedEntityChecker
getChecker()
Return the QuotedEntityChecker.
-
-
-
Constructor Detail
-
Template
public Template(@Nonnull String name, @Nonnull List<List<String>> rows) throws Exception
Given a template name and a list of rows, create a template object with a new IOHelper and QuotedEntityChecker. The rows are added to the object, new labels from the rows are added to the checker, and a Manchester Syntax parser is created.- Parameters:
name
- template namerows
- list of rows (lists)- Throws:
Exception
- on issue creating IOHelper or adding table to template object
-
Template
public Template(@Nonnull String name, @Nonnull List<List<String>> rows, IOHelper ioHelper) throws Exception
Given a template name, a list of rows, and an IOHelper, create a template object with a new QuotedEntityChecker. The rows are added to the object, new labels from the rows are added to the checker, and a Manchester Syntax parser is created.- Parameters:
name
- template namerows
- list of rows (lists)ioHelper
- IOHelper to resolve prefixes- Throws:
Exception
- on issue adding table to template object
-
Template
public Template(@Nonnull String name, @Nonnull List<List<String>> rows, org.semanticweb.owlapi.model.OWLOntology inputOntology) throws Exception
Given a template name, a list of rows, and an input ontology, create a template object with a new IOHelper and QuotedEntityChecker populated by the input ontology. The rows are added to the object, new labels from the rows are added to the checker, and a Manchester Syntax parser is created.- Parameters:
name
- template namerows
- list of rows (lists)inputOntology
- OWLOntology to get labels of entities for QuotedEntityChecker- Throws:
Exception
- on issue creating IOHelper or adding table to template object
-
Template
public Template(@Nonnull String name, @Nonnull List<List<String>> rows, org.semanticweb.owlapi.model.OWLOntology inputOntology, IOHelper ioHelper) throws Exception
Given a template name, a list of rows, an input ontology, and an IOHelper, create a template object with a new QuotedEntityChecker with the IOHelper populated by the input ontology. The rows are added to the object, new labels from the rows are added to the checker, and a Manchester Syntax parser is created.- Parameters:
name
- template namerows
- list of rows (lists)inputOntology
- OWLOntology to get labels of entities for QuotedEntityCheckerioHelper
- IOHelper to resolve prefixes- Throws:
Exception
- on issue adding table to template object
-
Template
public Template(@Nonnull String name, @Nonnull List<List<String>> rows, org.semanticweb.owlapi.model.OWLOntology inputOntology, IOHelper ioHelper, QuotedEntityChecker checker) throws Exception
Given a template name, a list of rows, an IOHelper, and a QuotedEntityChecker, create a template object. The rows are added to the object, new labels from the rows are added to the checker, and a Manchester Syntax parser is created.- Parameters:
name
- template namerows
- list of rows (lists)inputOntology
- OWLOntology to get labels of entities for QuotedEntityCheckerioHelper
- IOHelper to resolve prefixeschecker
- QuotedEntityChecker to get entities by label- Throws:
Exception
- on issue adding table to template object
-
-
Method Detail
-
getChecker
public QuotedEntityChecker getChecker()
Return the QuotedEntityChecker.- Returns:
- QuotedEntityChecker
-
generateOutputOntology
public org.semanticweb.owlapi.model.OWLOntology generateOutputOntology() throws Exception
Generate an OWLOntology based on the rows of the template.- Returns:
- new OWLOntology
- Throws:
Exception
- on issue parsing rows to axioms or creating new ontology
-
generateOutputOntology
public org.semanticweb.owlapi.model.OWLOntology generateOutputOntology(String outputIRI, boolean force) throws Exception
Generate an OWLOntology based on the rows of the template.- Parameters:
outputIRI
- IRI for final ontologyforce
- if true, do not exit on errors- Returns:
- new OWLOntology
- Throws:
Exception
- on issue parsing rows to axioms or creating new ontology
-
generateOutputOntology
public org.semanticweb.owlapi.model.OWLOntology generateOutputOntology(String outputIRI, boolean force, String errorsPath) throws Exception
Generate an OWLOntology with given IRI based on the rows of the template.- Parameters:
outputIRI
- IRI for final ontologyforce
- if true, do not exit on errorserrorsPath
- path to errors table when force=true- Returns:
- new OWLOntology
- Throws:
Exception
- on issue parsing rows to axioms or creating new ontology
-
-