CPQ modelling the intersection between CPQs (also known as the conjunction operation).
Method SummaryModifier and TypeMethodDescription
intReturns the diameter of this CPQ.
isLoop()Tests if this CPQ is a loop, meaning its source and target are the same.Computes and returns the query graph for this CPQ using the given source and target vertices for the computation.
toSQL()Converts this object to an SQL query.
voidWrites this object as XML to the given writer.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface dev.roanh.gmark.conjunct.cpq.CPQ
computeCore, isHomomorphicTo, toQueryGraph
cpqThe CPQs of the intersection.
IntersectionCPQConstructs a new intersection CPQ with the given CPQs to intersect.
cpq- The CPQs to intersect.
IllegalArgumentException- When less than two CPQs are provided.
toStringpublic String toString()
toSQLpublic String toSQL()Description copied from interface:
OutputSQLConverts this object to an SQL query.
writeXMLpublic void writeXML
(IndentWriter writer)Description copied from interface:
OutputXMLWrites this object as XML to the given writer.
toQueryGraphComputes and returns the query graph for this CPQ using the given source and target vertices for the computation. Usually using
CPQ.toQueryGraph()instead should be sufficient for most use cases, using this version instead can lead to unexpected results.
getDiameterpublic int getDiameter()Returns the diameter of this CPQ. The diameter of a CPQ is the largest number of labels to which the join operation is applied. A simpler way to think of this concept is the length of the largest path through the CPQ from source to target.
isLooppublic boolean isLoop()Tests if this CPQ is a loop, meaning its source and target are the same. When visualised as a query graph this means that the source and target node are the same node. In its grammar form this means that there is an intersection with identity at the highest level in the CPQ.