RadiusScope
extends BaseScope
in package
Class BoundsScope.
Table of Contents
Constants
- DEFAULT_LAT_FIELD = 'location_latitude'
- DEFAULT_LNG_FIELD = 'location_longitude'
- DEFAULT_MILES = 1
Properties
- $lat : float|null
- $latField : string|null
- $lng : float|null
- $lngField : string|null
- $radius : float|null
- $table : string|null
Methods
- apply() : mixed
- applyQueryBuilder() : void
- getLat() : float|null
- getLatField() : string|null
- getLng() : float|null
- getLngField() : string|null
- getRadius() : float|null
- getTable() : string|null
- likeOperator() : string
- return the case-insensitive LIKE operator bases on the current database driver.
- setLat() : $this
- setLatField() : $this
- setLng() : $this
- setLngField() : $this
- setRadius() : $this
- alias() : string
Constants
DEFAULT_LAT_FIELD
public
mixed
DEFAULT_LAT_FIELD
= 'location_latitude'
DEFAULT_LNG_FIELD
public
mixed
DEFAULT_LNG_FIELD
= 'location_longitude'
DEFAULT_MILES
public
mixed
DEFAULT_MILES
= 1
Properties
$lat
protected
float|null
$lat
= null
$latField
protected
string|null
$latField
= null
$lng
protected
float|null
$lng
= null
$lngField
protected
string|null
$lngField
= null
$radius
protected
float|null
$radius
= null
$table
protected
string|null
$table
= null
Methods
apply()
public
apply(Builder $builder, Model $model) : mixed
Parameters
- $builder : Builder
- $model : Model
applyQueryBuilder()
public
applyQueryBuilder(Builder $builder) : void
Parameters
- $builder : Builder
getLat()
public
getLat() : float|null
Return values
float|nullgetLatField()
public
getLatField() : string|null
Return values
string|nullgetLng()
public
getLng() : float|null
Return values
float|nullgetLngField()
public
getLngField() : string|null
Return values
string|nullgetRadius()
public
getRadius() : float|null
Return values
float|nullgetTable()
public
getTable() : string|null
Return values
string|nulllikeOperator()
return the case-insensitive LIKE operator bases on the current database driver.
public
likeOperator() : string
Return values
stringsetLat()
public
setLat(float|null $lat) : $this
Parameters
- $lat : float|null
Return values
$thissetLatField()
public
setLatField(string $field) : $this
Parameters
- $field : string
Return values
$thissetLng()
public
setLng(float|null $lng) : $this
Parameters
- $lng : float|null
Return values
$thissetLngField()
public
setLngField(string $field) : $this
Parameters
- $field : string
Return values
$thissetRadius()
public
setRadius(float|null $radius) : $this
Parameters
- $radius : float|null
Return values
$thisalias()
protected
alias(string $table, string $column) : string
Parameters
- $table : string
- $column : string