for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
declare(strict_types=1);
namespace Umbrellio\Postgres\Schema\Builders\Routines;
use Illuminate\Support\Fluent;
use Umbrellio\Postgres\Schema\Builders\Routines\Functions\ExecutionBuilder;
use Umbrellio\Postgres\Schema\Builders\Routines\Functions\FunctionArgumentBuilder;
use Umbrellio\Postgres\Schema\Builders\Routines\Functions\FunctionSecurityBuilder;
use Umbrellio\Postgres\Schema\Builders\Routines\Functions\FunctionSetBuilder;
use Umbrellio\Postgres\Schema\Builders\Routines\Functions\ParallelBuilder;
use Umbrellio\Postgres\Schema\Builders\Routines\Functions\StabilityBuilder;
class CreateFunctionBuilder extends Fluent
{
public function __call($method, $parameters)
switch ($method) {
case 'arg':
$command = new FunctionArgumentBuilder($this);
$this->attributes[$method] = call_user_func_array([$command, $method], $parameters);
break;
case 'stability':
$command = new StabilityBuilder($this);
case 'execution':
$command = new ExecutionBuilder($this);
case 'security':
$command = new FunctionSecurityBuilder($this);
case 'set':
$command = new FunctionSetBuilder($this);
case 'parallel':
$command = new ParallelBuilder($this);
default:
$command = $this;
}
parent::__call($method, $parameters);
return $command ?? $this;