private function visitComposite(Composite $composite) { $this->doVisit($composite->getConstraint1()); $this->doVisit($composite->getConstraint2()); }
private function visitComposite(Composite $composite) { if (!isset($this->compositeMap[$composite->getOperator()])) { throw new \InvalidArgumentException(sprintf('Unknown composite operator "%s", allowed "%s"', $composite->getOperator(), implode('", "', array_keys($this->compositeMap)))); } return sprintf('(%s %s %s)', $this->doVisit($composite->getConstraint1()), $this->compositeMap[$composite->getOperator()], $this->doVisit($composite->getConstraint2())); }