PHP Class Gitamin\Services\DataCollector\Eloquent\DataCollector

Inheritance: implements Gitamin\Services\DataCollector\Contracts\DataCollectorInterface, implements Gitamin\Services\DataCollector\Contracts\CriteriaInterface
Mostra file Open project: gitaminhq/gitamin

Protected Properties

Property Type Description
$app Illuminate\Container\Container
$criteria array
$model mixed
$skipCriteria boolean

Public Methods

Method Description
__call ( $method, $args ) : mixed
__construct ( Illuminate\Container\Container $app )
all ( array $columns = ['*'] ) : mixed
applyCriteria ( )
create ( array $data ) : mixed
delete ( $id ) : mixed
find ( $id, array $columns = ['*'] ) : mixed
findAllBy ( $attribute, $value, array $columns = ['*'] ) : mixed
findBy ( $attribute, $value, array $columns = ['*'] ) : mixed
findOrFail ( $id, array $columns = ['*'] ) : mixed
findOrNew ( $id, array $columns = ['*'] ) : mixed
findWhere ( array $where, array $columns = ['*'] ) : Illuminate\Database\Eloquent\Collection | null
getByCriteria ( Criteria $criteria )
getCriteria ( ) : mixed
lists ( string $value, string $key = null ) : array
makeModel ( ) : Model Creates instance of model.
pushCriteria ( Criteria $criteria )
raw ( mixed $value ) : Illuminate\Database\Query\Expression Get a new raw query expression.
resetCriteria ( )
resetScope ( )
skipCriteria ( boolean $flag = true )
update ( array $data, $id, string $attribute = 'id' ) : mixed

Protected Methods

Method Description
model ( $modelName = null )

Method Details

__call() public method

public __call ( $method, $args ) : mixed
$method
$args
return mixed

__construct() public method

public __construct ( Illuminate\Container\Container $app )
$app Illuminate\Container\Container

all() public method

public all ( array $columns = ['*'] ) : mixed
$columns array
return mixed

applyCriteria() public method

public applyCriteria ( )

create() public method

public create ( array $data ) : mixed
$data array
return mixed

delete() public method

public delete ( $id ) : mixed
$id
return mixed

find() public method

public find ( $id, array $columns = ['*'] ) : mixed
$id
$columns array
return mixed

findAllBy() public method

public findAllBy ( $attribute, $value, array $columns = ['*'] ) : mixed
$attribute
$value
$columns array
return mixed

findBy() public method

public findBy ( $attribute, $value, array $columns = ['*'] ) : mixed
$attribute
$value
$columns array
return mixed

findOrFail() public method

public findOrFail ( $id, array $columns = ['*'] ) : mixed
$id
$columns array
return mixed

findOrNew() public method

public findOrNew ( $id, array $columns = ['*'] ) : mixed
$id
$columns array
return mixed

findWhere() public method

public findWhere ( array $where, array $columns = ['*'] ) : Illuminate\Database\Eloquent\Collection | null
$where array
$columns array
return Illuminate\Database\Eloquent\Collection | null

getByCriteria() public method

public getByCriteria ( Criteria $criteria )
$criteria Gitamin\Services\DataCollector\Criteria\Criteria

getCriteria() public method

public getCriteria ( ) : mixed
return mixed

lists() public method

public lists ( string $value, string $key = null ) : array
$value string
$key string
return array

makeModel() public method

Creates instance of model.
public makeModel ( ) : Model
return Illuminate\Database\Eloquent\Model

model() abstract protected method

abstract protected model ( $modelName = null )

pushCriteria() public method

public pushCriteria ( Criteria $criteria )
$criteria Gitamin\Services\DataCollector\Criteria\Criteria

raw() public method

Get a new raw query expression.
public raw ( mixed $value ) : Illuminate\Database\Query\Expression
$value mixed
return Illuminate\Database\Query\Expression

resetCriteria() public method

public resetCriteria ( )

resetScope() public method

public resetScope ( )

skipCriteria() public method

public skipCriteria ( boolean $flag = true )
$flag boolean

update() public method

public update ( array $data, $id, string $attribute = 'id' ) : mixed
$data array
$id
$attribute string
return mixed

Property Details

$app protected_oe property

protected Container,Illuminate\Container $app
return Illuminate\Container\Container

$criteria protected_oe property

protected array $criteria
return array

$model protected_oe property

protected mixed $model
return mixed

$skipCriteria protected_oe property

protected bool $skipCriteria
return boolean