Class InternalOOLogicParser
java.lang.Object
com.semedy.reasoner.parser.oologic.InternalOOLogicParser
Parser for rules.
- Author:
- angele
-
Constructor Summary
ConstructorDescriptionInternalOOLogicParser
(SymbolTable symbolTable, ExternalDataTypeProvider dataTypeProvider, BuiltinProvider builtins, InvertedIndices invertedIndex) -
Method Summary
Modifier and TypeMethodDescriptionparse rule from a stringparseRules
(String input) parse several rules from input stringvoid
parseRulesOrFacts
(InputStream input, Collection<Rule> parsedRules, Collection<Literal> parsedFacts) parse rules and facts in input stream to the containers parsedRules and parsedFactsvoid
parseRulesOrFacts
(Reader input, Collection<Rule> parsedRules, Collection<Literal> parsedFacts) parse rules and facts from reader to the containers parsedRules and parsedFactsvoid
parseRulesOrFacts
(StringReader input, Collection<Rule> parsedRules, Collection<Literal> parsedFacts) parse rules and facts from string reader to the containers parsedRules and parsedFactsvoid
parseRulesOrFacts
(String input, Collection<Rule> parsedRules, Collection<Literal> parsedFacts) parse rules and facts from string to the containers parsedRules and parsedFacts
-
Constructor Details
-
InternalOOLogicParser
public InternalOOLogicParser(SymbolTable symbolTable, ExternalDataTypeProvider dataTypeProvider, BuiltinProvider builtins, InvertedIndices invertedIndex)
-
-
Method Details
-
parseRulesOrFacts
public void parseRulesOrFacts(InputStream input, Collection<Rule> parsedRules, Collection<Literal> parsedFacts) throws IOException, SemReasonerException parse rules and facts in input stream to the containers parsedRules and parsedFacts- Parameters:
input
- , input streamparsedRules
- , container to parse rules intoparsedFacts
- , container to parse facts into- Throws:
IOException
SemReasonerException
-
parseRulesOrFacts
public void parseRulesOrFacts(StringReader input, Collection<Rule> parsedRules, Collection<Literal> parsedFacts) throws IOException, SemReasonerException parse rules and facts from string reader to the containers parsedRules and parsedFacts- Parameters:
input
- , input string readerparsedRules
- , container to parse rules intoparsedFacts
- , container to parse facts into- Throws:
IOException
SemReasonerException
-
parseRulesOrFacts
public void parseRulesOrFacts(Reader input, Collection<Rule> parsedRules, Collection<Literal> parsedFacts) throws IOException, SemReasonerException parse rules and facts from reader to the containers parsedRules and parsedFacts- Parameters:
input
- , input readerparsedRules
- , container to parse rules intoparsedFacts
- , container to parse facts into- Throws:
IOException
SemReasonerException
-
parseRulesOrFacts
public void parseRulesOrFacts(String input, Collection<Rule> parsedRules, Collection<Literal> parsedFacts) throws SemReasonerException, IOException parse rules and facts from string to the containers parsedRules and parsedFacts- Parameters:
input
- , input stringparsedRules
- , container to parse rules intoparsedFacts
- , container to parse facts into- Throws:
IOException
SemReasonerException
-
parseRule
parse rule from a string- Parameters:
s
- input string- Returns:
- rule, resulting rule
- Throws:
IOException
SemReasonerException
-
parseRules
parse several rules from input string- Parameters:
input
- input string- Throws:
IOException
SemReasonerException
-