SpecialOfferReadService
in package
implements
SpecialOfferReadServiceInterface
Interfaces, Classes and Traits
- SpecialOfferReadServiceInterface
- Interface SpecialOfferReadServiceInterface
Table of Contents
- $repository : SpecialOfferRepositoryInterface
- __construct() : mixed
- SpecialOfferReadService constructor.
- getAll() : SpecialOfferCollection
- Returns all special offers.
- getBy() : SpecialOfferCollection
- Returns all special offers that matches the given search condition.
- getById() : SpecialOfferInterface
- Returns a special offer by the given id.
Properties
$repository
protected
SpecialOfferRepositoryInterface
$repository
Methods
__construct()
SpecialOfferReadService constructor.
public
__construct(SpecialOfferRepositoryInterface $repository) : mixed
Parameters
- $repository : SpecialOfferRepositoryInterface
Return values
mixed —getAll()
Returns all special offers.
public
getAll([Pager|null $pager = null ][, array<string|int, mixed> $sorters = [] ]) : SpecialOfferCollection
Parameters
- $pager : Pager|null = null
-
(Optional) Pager object with pagination information
- $sorters : array<string|int, mixed> = []
-
(Optional) array of Sorter objects with data sorting information
Return values
SpecialOfferCollection —List of special offers.
getBy()
Returns all special offers that matches the given search condition.
public
getBy(SpecialOfferSearchCondition $searchCondition[, Pager|null $pager = null ][, array<string|int, mixed> $sorters = [] ]) : SpecialOfferCollection
Parameters
- $searchCondition : SpecialOfferSearchCondition
-
Condition that must match for found items.
- $pager : Pager|null = null
-
(Optional) Pager object with pagination information
- $sorters : array<string|int, mixed> = []
-
(Optional) array of Sorter objects with data sorting information
Return values
SpecialOfferCollection —List of special offers by given conditions.
getById()
Returns a special offer by the given id.
public
getById(SpecialOfferIdInterface $specialOfferId) : SpecialOfferInterface
Parameters
- $specialOfferId : SpecialOfferIdInterface
-
Id of expected special offer.
Tags
Return values
SpecialOfferInterface —Special offer entity by given id.