for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
declare(strict_types=1);
namespace LaravelFreelancerNL\FluentAQL\Clauses;
use LaravelFreelancerNL\FluentAQL\Expressions\Expression;
use LaravelFreelancerNL\FluentAQL\QueryBuilder;
class GraphClause extends Clause
{
protected string|QueryBuilder|Expression $graphName;
public function __construct(string|QueryBuilder|Expression $graphName)
$this->graphName = $graphName;
}
public function compile(QueryBuilder $queryBuilder): string
$this->graphName = $queryBuilder->normalizeArgument($this->graphName, 'Graph');
return 'GRAPH ' . $this->graphName->compile($queryBuilder);