dpvis.datastructures.impl
Class DSFactory

java.lang.Object
  extended by dpvis.datastructures.impl.DSFactory

public class DSFactory
extends java.lang.Object


Constructor Summary
DSFactory()
           
 
Method Summary
static DependencyPairProblem createDependencyPairProblem(DependencyPairProblem dp)
          Creates a deep copy out of the given Dependency Pair Problem.
static DependencyPairProblem createDependencyPairProblem(java.util.Set<Rule> dependencyPairs, RewriteSystem rewriteSystem, java.util.Set<java.lang.String> signature)
          Constructs a new DependencyPairProblem out of the given parameters.
static DependencyPairProblem createDependencyPairProblem(java.util.Set<Rule> dependencyPairs, RewriteSystem rewriteSystem, java.util.Set<java.lang.String> signature, boolean contextSensitive, boolean minimal, boolean complete)
          Constructs a new DependencyPairProblem out of the given parameters.
static Term createMostGeneralTerm(java.lang.String function, int arity, java.util.List<java.lang.Integer> repMap)
          Creates the most general term for a function symbol with arity.
static RewriteSystem createRewriteSystem()
          Constructs a new empty Rewrite System.
static RewriteSystem createRewriteSystem(java.util.List<Rule> rules)
          Constructs a new Rewrite System with the given Rules.
static RewriteSystem createRewriteSystem(java.util.List<Rule> rules, Strategy strategy)
          Constructs a new Rewrite System out of the given rules and the strategy.
static RewriteSystem createRewriteSystem(RewriteSystem rs)
          Creates a deep copy of the given Rewrite System.
static Rule createRule(Rule rule)
          Creates a deep copy of the given rule.
static Rule createRule(Term lhs, Term rhs)
          Constructs a new unconditional Rule out of the given parameters.
static Rule createRule(Term lhs, Term rhs, java.util.List<Rule> conditions)
          Constructs a new conditional Rule out of the given parameters.
static Strategy createStrategy(int type)
          Constructs a new Strategy out of the given type.
static Strategy createStrategy(int type, java.util.Map<java.lang.String,java.util.List<java.lang.Integer>> replacementMap)
          Constructs a new Strategy out of the given type and replacement map.
static Strategy createStrategy(Strategy strategy)
          Creates a deep copy of the given Strategy.
static Substitution createSubstitution()
          Constructs a new empty Substitution.
static Term createTerm(java.lang.String term)
          Creates a term from the given string representation.
static Term createTerm(java.lang.String function, java.util.List<Term> subterms, boolean variable)
          Constructs a new Term out of the given parameters.
static Term createTerm(java.lang.String function, java.util.List<Term> subterms, boolean forbidden, boolean variable)
          Constructs a new Term out of the given parameters.
static Term createTerm(Term term)
          Creates a deep copy of the given term.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DSFactory

public DSFactory()
Method Detail

createDependencyPairProblem

public static DependencyPairProblem createDependencyPairProblem(java.util.Set<Rule> dependencyPairs,
                                                                RewriteSystem rewriteSystem,
                                                                java.util.Set<java.lang.String> signature)
Constructs a new DependencyPairProblem out of the given parameters. Minimal and completeness flags are set.


createDependencyPairProblem

public static DependencyPairProblem createDependencyPairProblem(java.util.Set<Rule> dependencyPairs,
                                                                RewriteSystem rewriteSystem,
                                                                java.util.Set<java.lang.String> signature,
                                                                boolean contextSensitive,
                                                                boolean minimal,
                                                                boolean complete)
Constructs a new DependencyPairProblem out of the given parameters.


createDependencyPairProblem

public static DependencyPairProblem createDependencyPairProblem(DependencyPairProblem dp)
Creates a deep copy out of the given Dependency Pair Problem.


createRewriteSystem

public static RewriteSystem createRewriteSystem()
Constructs a new empty Rewrite System.


createRewriteSystem

public static RewriteSystem createRewriteSystem(java.util.List<Rule> rules)
Constructs a new Rewrite System with the given Rules. No strategy is used.


createRewriteSystem

public static RewriteSystem createRewriteSystem(RewriteSystem rs)
Creates a deep copy of the given Rewrite System.


createRewriteSystem

public static RewriteSystem createRewriteSystem(java.util.List<Rule> rules,
                                                Strategy strategy)
Constructs a new Rewrite System out of the given rules and the strategy.


createRule

public static Rule createRule(Term lhs,
                              Term rhs)
Constructs a new unconditional Rule out of the given parameters.


createRule

public static Rule createRule(Term lhs,
                              Term rhs,
                              java.util.List<Rule> conditions)
Constructs a new conditional Rule out of the given parameters.


createRule

public static Rule createRule(Rule rule)
Creates a deep copy of the given rule.


createStrategy

public static Strategy createStrategy(int type)
Constructs a new Strategy out of the given type.


createStrategy

public static Strategy createStrategy(int type,
                                      java.util.Map<java.lang.String,java.util.List<java.lang.Integer>> replacementMap)
Constructs a new Strategy out of the given type and replacement map.


createStrategy

public static Strategy createStrategy(Strategy strategy)
Creates a deep copy of the given Strategy.


createSubstitution

public static Substitution createSubstitution()
Constructs a new empty Substitution.


createTerm

public static Term createTerm(java.lang.String function,
                              java.util.List<Term> subterms,
                              boolean forbidden,
                              boolean variable)
Constructs a new Term out of the given parameters.


createTerm

public static Term createTerm(java.lang.String function,
                              java.util.List<Term> subterms,
                              boolean variable)
Constructs a new Term out of the given parameters.


createTerm

public static Term createTerm(Term term)
Creates a deep copy of the given term.


createTerm

public static Term createTerm(java.lang.String term)
Creates a term from the given string representation. E.g. f(g(x, y), z). All function symbols that start with x, y or z are treated as variables. This constructor may be useful for debugging.

Parameters:
term - The string representation of the term
Returns:
The term object constructed from the string, or null if the string cannot be parsed.

createMostGeneralTerm

public static Term createMostGeneralTerm(java.lang.String function,
                                         int arity,
                                         java.util.List<java.lang.Integer> repMap)
Creates the most general term for a function symbol with arity. The replacement map specifies which subterms are marked as forbidden. E.g. the parameters f, 3, [2, 3] produce the term f([x_1], x_2, x_3), where [x_1] means that the subterm x_1 is forbidden.