Class ConjunctGeneratorCPQ

java.lang.Object
dev.roanh.gmark.query.conjunct.cpq.ConjunctGeneratorCPQ
All Implemented Interfaces:
ConjunctGenerator

public class ConjunctGeneratorCPQ extends Object implements ConjunctGenerator
Conjunct generator for CPQs (Conjunctive Path Queries).
See Also:
  • Field Details

    • gs

      private SchemaGraph gs
      The schema graph to use to generate CPQs.
    • workload

      private WorkloadCPQ workload
      The workload specifying what CPQs to generate.
  • Constructor Details

    • ConjunctGeneratorCPQ

      public ConjunctGeneratorCPQ(WorkloadCPQ wl)
      Constructs a new CPQ conjunct generator using the given workload.
      Parameters:
      wl - The workload specification.
      See Also:
  • Method Details

    • generateConjunct

      public Conjunct generateConjunct(SelectivityGraph gSel, SelectivityType start, SelectivityType end, Variable source, Variable target, boolean star) throws GenerationException
      Description copied from interface: ConjunctGenerator
      Generates a single conjunct using the given selectivity graph and with the start of the conjunct being the given start selectivity type and the end of the conjunct the given end selectivity type.
      Specified by:
      generateConjunct in interface ConjunctGenerator
      Parameters:
      gSel - The selectivity graph to use (if required).
      start - The starting selectivity type of the conjunct to generate.
      end - The end selectivity type of the conjunct to generate.
      source - The source variable of the conjunct.
      target - The target variable of the conjunct.
      star - True if the conjunct should have a Kleene star above it.
      Returns:
      The randomly generated conjunct.
      Throws:
      GenerationException - When some exception occurred that prevented a conjunct from begin generated.