Skip to content

Commit

Permalink
Use this return type for builders @methods
Browse files Browse the repository at this point in the history
  • Loading branch information
bastien-phi committed Jan 3, 2025
1 parent 0550840 commit 3efdb17
Showing 1 changed file with 21 additions and 21 deletions.
42 changes: 21 additions & 21 deletions src/NextIdeHelper/Extension.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,27 +22,27 @@ public function execute(Model $model): void
Collection::make([
'bool insertModels(array $values)',
'int upsertModels(array $values, string|array $uniqueBy, ?array $update = null)',
"{$builderClass} scope(\\Illuminate\\Database\\Eloquent\\Scope \$scope)",
"{$builderClass} scoped(\\Closure \$callable)",
"{$builderClass} preventInvalidDirection(string \$direction)",
"{$builderClass} withAggregateFunction(array \$relations, \\Soyhuce\\EloquentExtended\\Aggregates\\Contracts\\AggregateFunction \$aggregateFunction)",
"{$builderClass} withAnyExists(array \$relations, string \$alias = 'related_exists')",
"{$builderClass} withImplode(array|string \$relations, string \$column, string \$glue, ?string \$orderBy = null, string \$direction = 'asc')",
"{$builderClass} orderByNullsLast(string \$column, string \$direction = 'asc')",
"{$builderClass} orderByRawNullsLast(string \$sql)",
"{$builderClass} orderByNullsFirst(string \$column, string \$direction = 'asc')",
"{$builderClass} orderByRawNullsFirst(string \$sql)",
"{$builderClass} orderByAggregate(string \$relationName, string \$column, string \$direction = 'asc', ?string \$function = null, ?\\Closure \$constraints = null)",
"{$builderClass} orderByExists(string \$relation, ?\\Closure \$constraints = null, string \$direction = 'asc')",
"{$builderClass} orderByExistsDesc(string \$relation, ?\\Closure \$constraints = null)",
"{$builderClass} orderByCount(string \$relation, ?\\Closure \$constraints = null, string \$direction = 'asc')",
"{$builderClass} orderByCountDesc(string \$relation, ?\\Closure \$constraints = null)",
"{$builderClass} orderBySum(string \$relation, string \$column, ?\\Closure \$constraints = null, string \$direction = 'asc')",
"{$builderClass} orderBySumDesc(string \$relation, string \$column, ?\\Closure \$constraints = null)",
"{$builderClass} orderByMin(string \$relation, string \$column, ?\\Closure \$constraints = null, string \$direction = 'asc')",
"{$builderClass} orderByMinDesc(string \$relation, string \$column, ?\\Closure \$constraints = null)",
"{$builderClass} orderByMax(string \$relation, string \$column, ?\\Closure \$constraints = null, string \$direction = 'asc')",
"{$builderClass} orderByMaxDesc(string \$relation, string \$column, ?\\Closure \$constraints = null)",
'$this scope(\\Illuminate\\Database\\Eloquent\\Scope $scope)',
'$this scoped(\\Closure $callable)',
'$this preventInvalidDirection(string $direction)',
'$this withAggregateFunction(array $relations, \\Soyhuce\\EloquentExtended\\Aggregates\\Contracts\\AggregateFunction $aggregateFunction)',
'$this withAnyExists(array $relations, string $alias = \'related_exists\')',
'$this withImplode(array|string $relations, string $column, string $glue, ?string $orderBy = null, string $direction = \'asc\')',
'$this orderByNullsLast(string $column, string $direction = \'asc\')',
'$this orderByRawNullsLast(string $sql)',
'$this orderByNullsFirst(string $column, string $direction = \'asc\')',
'$this orderByRawNullsFirst(string $sql)',
'$this orderByAggregate(string $relationName, string $column, string $direction = \'asc\', ?string $function = null, ?\\Closure $constraints = null)',
'$this orderByExists(string $relation, ?\\Closure $constraints = null, string $direction = \'asc\')',
'$this orderByExistsDesc(string $relation, ?\\Closure $constraints = null)',
'$this orderByCount(string $relation, ?\\Closure $constraints = null, string $direction = \'asc\')',
'$this orderByCountDesc(string $relation, ?\\Closure $constraints = null)',
'$this orderBySum(string $relation, string $column, ?\\Closure $constraints = null, string $direction = \'asc\')',
'$this orderBySumDesc(string $relation, string $column, ?\\Closure $constraints = null)',
'$this orderByMin(string $relation, string $column, ?\\Closure $constraints = null, string $direction = \'asc\')',
'$this orderByMinDesc(string $relation, string $column, ?\\Closure $constraints = null)',
'$this orderByMax(string $relation, string $column, ?\\Closure $constraints = null, string $direction = \'asc\')',
'$this orderByMaxDesc(string $relation, string $column, ?\\Closure $constraints = null)',
"{$modelClass}|null random()",
])
->when(
Expand Down

0 comments on commit 3efdb17

Please sign in to comment.