Package org.evrete.api.spi
Interface DSLKnowledgeProvider
public interface DSLKnowledgeProvider
-
Method Summary
Modifier and Type Method Description default voidapply(RuntimeContext<?> targetContext, InputStream... inputStreams)Deprecated.default voidapply(RuntimeContext<?> targetContext, Reader... readers)Deprecated.default voidapply(RuntimeContext<?> targetContext, URL... resources)Deprecated.Knowledgecreate(KnowledgeService service, InputStream... streams)default Knowledgecreate(KnowledgeService service, Reader... streams)Knowledgecreate(KnowledgeService service, URL... resources)Given the sources' URLs, the DSL implementation must return a new Knowledge instance.StringgetName()
-
Method Details
-
getName
String getName() -
create
Given the sources' URLs, the DSL implementation must return a new Knowledge instance. Depending on the DSL implementation, URLs may refer to plain text resources, Java classes/archives, JDBC connection strings, files, etc.
- Parameters:
resources- remote or local resources to applyservice- Knowledge service.- Throws:
IOException
-
create
- Parameters:
streams- remote or local resources to applyservice- Knowledge service.- Throws:
IOException- See Also:
create(KnowledgeService, URL...)
-
create
- Parameters:
streams- remote or local resources to applyservice- Knowledge service.- Throws:
IOException- if resources can not be readUnsupportedOperationException- if this method is not supported by the implementation- See Also:
create(KnowledgeService, URL...)
-
apply
@Deprecated default void apply(RuntimeContext<?> targetContext, URL... resources) throws IOExceptionDeprecated.Given the sources' URLs, the DSL implementation must compile and append rules to the provided context.
- Parameters:
targetContext- the runtime to append rules toresources- remote or local resources to apply- Throws:
IOException
-
apply
@Deprecated default void apply(RuntimeContext<?> targetContext, InputStream... inputStreams) throws IOExceptionDeprecated.Given the input stream, the DSL implementation must compile and append rules to the provided context.
- Parameters:
targetContext- the runtime to append rules toinputStreams- input streams to ruleset sources- Throws:
IOException
-
apply
@Deprecated default void apply(RuntimeContext<?> targetContext, Reader... readers) throws IOExceptionDeprecated.- Parameters:
targetContext- the runtime to append rules toreaders- readers of ruleset sources- Throws:
IOException- See Also:
apply(RuntimeContext, InputStream...)
-