PHP Класс PartKeepr\SetupBundle\Services\UnitSetupService

Показать файл Открыть проект

Открытые методы

Метод Описание
__construct ( EntityManager $entityManager, Symfony\Component\HttpKernel\KernelInterface $kernel ) UnitSetupService constructor.
importUnits ( ) : array Imports units.

Защищенные методы

Метод Описание
getSiPrefix ( string $name ) : SiPrefix | null Finds an SI Prefix by name.
getUnit ( string $name ) : Unit | null Checks if the specified SI Prefix.

Описание методов

__construct() публичный Метод

UnitSetupService constructor.
public __construct ( EntityManager $entityManager, Symfony\Component\HttpKernel\KernelInterface $kernel )
$entityManager Doctrine\ORM\EntityManager
$kernel Symfony\Component\HttpKernel\KernelInterface

getSiPrefix() защищенный Метод

Finds an SI Prefix by name.
protected getSiPrefix ( string $name ) : SiPrefix | null
$name string The SI Prefix name
Результат PartKeepr\SiPrefixBundle\Entity\SiPrefix | null

getUnit() защищенный Метод

Checks if the specified SI Prefix.
protected getUnit ( string $name ) : Unit | null
$name string The footprint name
Результат PartKeepr\UnitBundle\Entity\Unit | null

importUnits() публичный Метод

Imports units.
public importUnits ( ) : array
Результат array An array with the keys "skipped" and "imported" which contain the number of units skipped and imported