QuantityUnitRepository

Implements \QuantityUnitRepositoryInterface

Class QuantityUnitRepository

category

System

package

QuantityUnit

subpackage

Repositories

Methods

QuantityUnitRepository constructor.

__construct(\QuantityUnitStorageInterface $storage, \QuantityUnitFactory $factory, \LanguageProvider $languageProvider) 

Arguments

$languageProvider

\LanguageProvider

Creates Quantity unit entity.

createQuantityUnit() : \GXEngineQuantityUnit

Response

\GXEngineQuantityUnit

New quantity unit entity.

Deletes quantity unit entity from database.

delete(\QuantityUnitInterface $quantityUnit) : \QuantityUnitRepositoryInterface

Arguments

$quantityUnit

\QuantityUnitInterface

Quantity unit entity to be deleted.

Response

\QuantityUnitRepositoryInterface

Same instance for chained method calls.

Returns all quantity unit as collection.

getAll() : \QuantityUnitCollection

Response

\QuantityUnitCollection

Quantity unit collection.

Returns quantity unit entity by the given id.

getById(\IdType $quantityUnitId) : \QuantityUnitInterface

Arguments

$quantityUnitId

\IdType

IdType of entity to be returned.

Response

\QuantityUnitInterface

Saves quantity unit entity in database.

save(\QuantityUnitInterface $quantityUnit) : \QuantityUnitRepositoryInterface

Arguments

$quantityUnit

\QuantityUnitInterface

Quantity unit to be save.

Response

\QuantityUnitRepositoryInterface

Same instance for chained method calls.

Properties

storage

storage : \QuantityUnitStorageInterface

factory

factory : \QuantityUnitFactory
var

Type(s)

\QuantityUnitFactory

languageProvider

languageProvider : \LanguageProvider
var

Type(s)

\LanguageProvider