public abstract class AbstractRule extends Object implements Rule
| Modifier and Type | Field and Description |
|---|---|
protected Consumer<RhsContext> |
rhs |
| Modifier | Constructor and Description |
|---|---|
protected |
AbstractRule(AbstractRule other,
String ruleName,
int salience) |
protected |
AbstractRule(String name,
int defaultSalience) |
| Modifier and Type | Method and Description |
|---|---|
Rule |
addImport(RuleScope scope,
String imp) |
protected void |
appendImports(Imports parent) |
void |
chainRhs(Consumer<RhsContext> consumer) |
<T> T |
get(String property) |
Imports |
getImports() |
protected String |
getLiteralRhs() |
String |
getName() |
Collection<String> |
getPropertyNames() |
Consumer<RhsContext> |
getRhs() |
int |
getSalience() |
Rule |
set(String property,
Object value) |
void |
setRhs(Consumer<RhsContext> rhs) |
void |
setRhs(String literalRhs) |
void |
setSalience(int salience) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetaddImport, getJavaImportsresolveprotected Consumer<RhsContext> rhs
protected AbstractRule(String name, int defaultSalience)
protected AbstractRule(AbstractRule other, String ruleName, int salience)
protected void appendImports(Imports parent)
public Imports getImports()
getImports in interface FluentImports<Rule>public Rule addImport(RuleScope scope, String imp)
addImport in interface FluentImports<Rule>public Consumer<RhsContext> getRhs()
public Collection<String> getPropertyNames()
getPropertyNames in interface Environmentprotected String getLiteralRhs()
public final int getSalience()
getSalience in interface Rulepublic void setSalience(int salience)
setSalience in interface Rulepublic Rule set(String property, Object value)
set in interface Environmentset in interface FluentEnvironment<Rule>public final <T> T get(String property)
get in interface Environmentpublic void setRhs(Consumer<RhsContext> rhs)
public void chainRhs(Consumer<RhsContext> consumer)
Copyright © 2021. All rights reserved.