5use InvalidArgumentException;
27 $this->children[] = $expression;
30 abstract protected function getType(): string;
38 if ( !$this->children ) {
39 throw new InvalidArgumentException(
"The array of values can't be empty." );
41 $sqls = array_map(
static fn ( $value ) => $value->toSql( $dbQuoter ), $this->children );
42 return '(' . implode(
' ' . $this->
getType() .
' ', $sqls ) .
')';
46 if ( !$this->children ) {
47 throw new InvalidArgumentException(
"The array of values can't be empty." );
49 $sqls = array_map(
static fn ( $value ) => $value->toGeneralizedSql(), $this->children );
50 return '(' . implode(
' ' . $this->getType() .
' ', $sqls ) .
')';
if(!defined('MW_SETUP_CALLBACK'))