ManufacturerRepositoryInterface
in
Interface ManufacturerRepositoryInterface
Tags
Table of Contents
- createManufacturer() : Manufacturer
- creates manufacturer entity.
- delete() : ManufacturerRepositoryInterface
- Deletes manufacturer entity from database.
- getAll() : ManufacturerCollection
- Returns all manufacturer as collection.
- getById() : ManufacturerInterface
- Returns manufacturer entity by the given id.
- save() : ManufacturerRepositoryInterface
- Saves manufacturer entity in database.
- search() : ManufacturerCollection
- Searches for manufacturer entities that respects the given search condition and returns their data as a collection.
Methods
createManufacturer()
creates manufacturer entity.
public
createManufacturer() : Manufacturer
Return values
Manufacturer —New manufacturer entity.
delete()
Deletes manufacturer entity from database.
public
delete(ManufacturerInterface $manufacturer) : ManufacturerRepositoryInterface
Parameters
- $manufacturer : ManufacturerInterface
-
Manufacturer entity to be deleted.
Return values
ManufacturerRepositoryInterface —Same instance for chained method calls.
getAll()
Returns all manufacturer as collection.
public
getAll() : ManufacturerCollection
Return values
ManufacturerCollection —Manufacturer collection.
getById()
Returns manufacturer entity by the given id.
public
getById(IdType $manufacturerId) : ManufacturerInterface
Parameters
- $manufacturerId : IdType
-
IdType of entity to be returned.
Tags
Return values
ManufacturerInterface —save()
Saves manufacturer entity in database.
public
save(ManufacturerInterface $manufacturer) : ManufacturerRepositoryInterface
Parameters
- $manufacturer : ManufacturerInterface
-
Manufacturer entity to be saved.
Return values
ManufacturerRepositoryInterface —Same instance for chained method calls.
search()
Searches for manufacturer entities that respects the given search condition and returns their data as a collection.
public
search(ManufacturerSearchCondition $searchCondition[, Pager|null $pager = null ][, array<string|int, mixed> $sorters = [] ]) : ManufacturerCollection
Parameters
- $searchCondition : ManufacturerSearchCondition
- $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
ManufacturerCollection —Manufacturer collection.