Exists
class Exists
Properties
protected string | $table | The table to run the query against. |
|
protected string | $column | The column to check for existence on. |
|
protected array | $wheres | There extra where clauses for the query. |
|
protected Closure|null | $using | The custom query callback. |
Methods
Create a new exists rule instance.
Set a "where" constraint on the query.
Set a "where not" constraint on the query.
Set a "where null" constraint on the query.
Set a "where not null" constraint on the query.
Format the where clauses.
Get the custom query callbacks for the rule.
Convert the rule to a validation string.
Details
at line 44
void
__construct(string $table, string $column = 'NULL')
Create a new exists rule instance.
at line 57
$this
where(string $column, string $value = null)
Set a "where" constraint on the query.
at line 75
$this
whereNot(string $column, string $value)
Set a "where not" constraint on the query.
at line 86
$this
whereNull(string $column)
Set a "where null" constraint on the query.
at line 97
$this
whereNotNull(string $column)
Set a "where not null" constraint on the query.
at line 108
$this
using(Closure $callback)
Register a custom query callback.
at line 120
protected string
formatWheres()
Format the where clauses.
at line 132
array
queryCallbacks()
Get the custom query callbacks for the rule.
at line 142
string
__toString()
Convert the rule to a validation string.