W3cubDocs

/Laravel 8

DatabasePresenceVerifierInterface

interface DatabasePresenceVerifierInterface implements PresenceVerifierInterface (View source)

Methods

int getCount(string $collection, string $column, string $value, int|null $excludeId = null, string|null $idColumn = null, array $extra = [])

Count the number of objects in a collection having the given value.

from PresenceVerifierInterface
int getMultiCount(string $collection, string $column, array $values, array $extra = [])

Count the number of objects in a collection with the given values.

from PresenceVerifierInterface
void setConnection(string $connection)

Set the connection to be used.

Details

int getCount(string $collection, string $column, string $value, int|null $excludeId = null, string|null $idColumn = null, array $extra = [])

Count the number of objects in a collection having the given value.

Parameters

string $collection
string $column
string $value
int|null $excludeId
string|null $idColumn
array $extra

Return Value

int

int getMultiCount(string $collection, string $column, array $values, array $extra = [])

Count the number of objects in a collection with the given values.

Parameters

string $collection
string $column
array $values
array $extra

Return Value

int

void setConnection(string $connection)

Set the connection to be used.

Parameters

string $connection

Return Value

void

© Taylor Otwell
Licensed under the MIT License.
Laravel is a trademark of Taylor Otwell.
https://laravel.com/api/8.x/Illuminate/Validation/DatabasePresenceVerifierInterface.html