org.encog.ml.ea.rules
public class BasicRuleHolder extends Object implements RuleHolder
| Constructor and Description |
|---|
BasicRuleHolder() |
| Modifier and Type | Method and Description |
|---|---|
void |
addConstraintRule(ConstraintRule rule)
Add a constraint rule.
|
void |
addRewriteRule(RewriteRule rule)
Add a rewrite rule.
|
List<ConstraintRule> |
getConstraintRules() |
List<RewriteRule> |
getRewriteRules() |
boolean |
isValid(Genome genome)
Determine if the specified genome is valid according to the constraint rules.
|
void |
rewrite(Genome prg)
Rewrite the specified genome.
|
public void addRewriteRule(RewriteRule rule)
addRewriteRule in interface RuleHolderrule - The rule to add.public void rewrite(Genome prg)
rewrite in interface RuleHolderprg - The genome to rewrite.public void addConstraintRule(ConstraintRule rule)
addConstraintRule in interface RuleHolderrule - The rule to add.public boolean isValid(Genome genome)
isValid in interface RuleHoldergenome - The gnome to check.public List<ConstraintRule> getConstraintRules()
getConstraintRules in interface RuleHolderpublic List<RewriteRule> getRewriteRules()
getRewriteRules in interface RuleHolderCopyright © 2014. All Rights Reserved.