Class RuleSet<T extends Rule<?,​?>>

  • Type Parameters:
    T - the specific rule class
    All Implemented Interfaces:
    Serializable, Cloneable, Iterable<T>, Collection<T>, Set<T>

    public class RuleSet<T extends Rule<?,​?>>
    extends HashSet<T>
    This class represents a set of rules and provides several auxiliary methods for accessing such a set.
    Author:
    Matthias Thimm, Tim Janus
    See Also:
    Serialized Form
    • Constructor Detail

      • RuleSet

        public RuleSet()
        Creates a new empty rule set.
      • RuleSet

        public RuleSet​(Collection<? extends T> rules)
        Creates a new rule set with the given rules
        Parameters:
        rules - a collection of rules.
    • Method Detail

      • getRulesWithConclusion

        public Set<T> getRulesWithConclusion​(Formula f)
        Returns all rules this set with the given conclusion
        Parameters:
        f - a formula
        Returns:
        all rules this set with the given conclusion
      • getConclusions

        public Set<Formula> getConclusions()
        Returns all conclusions of all rules of this rule set.
        Returns:
        all conclusions of all rules of this rule set.
      • getPremises

        public Set<Formula> getPremises()
        Returns all premises appearing in this rule set.
        Returns:
        all premises appearing in this rule set.
      • getSyntacticModule

        public RuleSet<T> getSyntacticModule​(Formula f)
        Returns the maximal subset of this rule set that is closed under "syntactic" neighbourhood relationship for the given formula. A formula/rule has a "syntactic" neighbourhood relationship with a rule iff they share vocabulary elements.
        Parameters:
        f - some formula
        Returns:
        a rule set.