@param string $family

@return \Interpro\Core\Taxonomy\Collections\TypesCollection
336769
public function getFamily($family)
    {
        if(array_key_exists($family, $this->familyTypes))
        {
            return $this->familyTypes[$family];
        }
        else
        {
            throw new TaxonomyException('Не найдена коллекция типов пакета '.$family);
        }
    }
490447
public function getType( $series = null )
    {
        $series = $series ?: 'default';
        $seriesTitle = $this->getSeriesTitle( $series );
        
        return isset( $this->types[$seriesTitle] ) ? $this->types[$seriesTitle] : null;
    }
410477
protected function getCollection($type)
    {
        $collection = new ArrayCollection();
        $key        = $this->config[$type]['key'];
        $hydrator   = $this->getHydrator($type);
        $filter     = 'filter' . rtrim($type, 's');
        $entity     = $this->getEntity($type);
        $dataArray  = $this->getData($key);
        
        if ($dataArray) {
            foreach ($dataArray as $data) {
                $data    = $this->$filter($data);
                if (!count($data)) {
                    continue;
                }
                $current = $hydrator->hydrate($data, clone $entity);
                $collection->add($current);
            }
        }
        return $collection;
    }
1103208
public function getADestructor($family)
    {
        if(!array_key_exists($family, $this->destructorsA))
        {
            throw new CoreException('Деструктор агрегатных(A) типов пакета '.$family.' не найдена в медиаторе!');
        }

        return $this->destructorsA[$family];
    }
1358058
protected function getFamilyConfig($family)
    {
        if (!isset($this->config[$family])) {
            throw new \InvalidArgumentException(
                sprintf('Undefined measure family "%s"', $family)
            );
        }

        return $this->config[$family];
    }
1305808
protected function getFileHeader(FamilyInterface $family)
    {
        $content = <<<EOT
<?php

namespace Sidus\EAV;

use Doctrine\Common\Collections\Collection;

abstract class {$family->getCode()} extends 
EOT;
        if ($family->getParent()) {
            $content .= $family->getParent()->getCode();
        } else {
            $content .= '\\'.$family->getDataClass();
        }
        $content .= "\n{\n";

        return $content;
    }
688822
public function getAInitializer($family)
    {
        if(!array_key_exists($family, $this->initializersA))
        {
            throw new CoreException('Инициализатор агрегатных(A) типов пакета '.$family.' не найдена в медиаторе!');
        }

        return $this->initializersA[$family];
    }
1186752
public function joinTablesOnCollectionByType($collection, $type)
    {
        if ($type == \Dotdigitalgroup\Email\Model\Rules::ABANDONED) {
            $collection->getSelect()
                ->joinLeft(
                    ['quote_address' => $this->getTable('quote_address')],
                    'main_table.entity_id = quote_address.quote_id',
                    ['shipping_method', 'country_id', 'city', 'region_id']
                )->joinLeft(
                    ['quote_payment' => $this->getTable('quote_payment')],
                    'main_table.entity_id = quote_payment.quote_id',
                    ['method']
                )->where('address_type = ?', 'shipping');
        } elseif ($type == \Dotdigitalgroup\Email\Model\Rules::REVIEW) {
            $collection->getSelect()
                ->join(
                    ['order_address' => $this->getTable('sales_order_address')],
                    'main_table.entity_id = order_address.parent_id',
                    ['country_id', 'city', 'region_id']
                )->join(
                    ['order_payment' => $this->getTable('sales_order_payment')],
                    'main_table.entity_id = order_payment.parent_id',
                    ['method']
                )->where('order_address.address_type = ?', 'shipping');
        }

        return $collection;
    }
604811
public function noChildrenFamiliesList($type = 'list'): string
    {
        $families = DB::table('families')
            ->where('f_file', '=', $this->tree->id())
            ->where('f_numchil', '=', 0)
            ->get()
            ->map(Family::rowMapper())
            ->filter(GedcomRecord::accessFilter());

        $top10 = [];

        /** @var Family $family */
        foreach ($families as $family) {
            if ($type === 'list') {
                $top10[] = '<li><a href="' . e($family->url()) . '">' . $family->fullName() . '</a></li>';
            } else {
                $top10[] = '<a href="' . e($family->url()) . '">' . $family->fullName() . '</a>';
            }
        }

        if ($type === 'list') {
            $top10 = implode('', $top10);
        } else {
            $top10 = implode('; ', $top10);
        }


        if ($type === 'list') {
            return '<ul>' . $top10 . '</ul>';
        }

        return $top10;
    }
732908
private function addFamilyAndDescendantsToCart(Family $family): void
    {
        $this->addRecordToCart($family);

        foreach ($family->spouses() as $spouse) {
            $this->addRecordToCart($spouse);
        }
        foreach ($family->children() as $child) {
            $this->addRecordToCart($child);
            foreach ($child->spouseFamilies() as $child_family) {
                $this->addFamilyAndDescendantsToCart($child_family);
            }
        }
    }
915421
public function getCollection($collectionClass = CreateFromAttributesInterface::class)
    {
        $collection = [];
        if ($this->isSuccessful()) {
            $data = $this->getData();
            foreach ($data as $attributes) {
                /** @var AbstractModel $collectionClass */
                $collection[] = $collectionClass::createFromAttributes($attributes);
            }
        }

        return $collection;
    }
1159977
public function get_font_families() {
        $families = array();
        foreach ($this->fontlist as $font) {
            if (strpos($font, 'uni2cid') === 0) {
                // This is not an font file.
                continue;
            }
            if (strpos($font, 'cid0') === 0) {
                // These do not seem to work with utf-8, better ignore them for now.
                continue;
            }
            if (substr($font, -2) === 'bi') {
                $family = substr($font, 0, -2);
                if (in_array($family, $this->fontlist)) {
                    $families[$family]['BI'] = 'BI';
                    continue;
                }
            }
            if (substr($font, -1) === 'i') {
                $family = substr($font, 0, -1);
                if (in_array($family, $this->fontlist)) {
                    $families[$family]['I'] = 'I';
                    continue;
                }
            }
            if (substr($font, -1) === 'b') {
                $family = substr($font, 0, -1);
                if (in_array($family, $this->fontlist)) {
                    $families[$family]['B'] = 'B';
                    continue;
                }
            }
            // This must be a Family or incomplete set of fonts present.
            $families[$font]['R'] = 'R';
        }

        // Sort everything consistently.
        ksort($families);
        foreach ($families as $k => $v) {
            krsort($families[$k]);
        }

        return $families;
    }
527624
public function spouseStepFamilies(): Collection
    {
        $step_families = [];
        $families      = $this->spouseFamilies();

        foreach ($families as $family) {
            $spouse = $family->spouse($this);

            if ($spouse) {
                foreach ($family->spouse($this)->spouseFamilies() as $step_family) {
                    if (!$families->containsStrict($step_family)) {
                        $step_families[] = $step_family;
                    }
                }
            }
        }

        return new Collection($step_families);
    }
107232
protected function setFamily(FamilyInterface $family)
    {
        $this->family = $family;
        $this->container->get('router')->getContext()->setParameter('familyCode', $family->getCode());
    }
168277
public function childStepFamilies(): Collection
    {
        $step_families = [];
        $families      = $this->childFamilies();
        foreach ($families as $family) {
            $father = $family->husband();
            if ($father) {
                foreach ($father->spouseFamilies() as $step_family) {
                    if (!$families->containsStrict($step_family)) {
                        $step_families[] = $step_family;
                    }
                }
            }
            $mother = $family->wife();
            if ($mother) {
                foreach ($mother->spouseFamilies() as $step_family) {
                    if (!$families->containsStrict($step_family)) {
                        $step_families[] = $step_family;
                    }
                }
            }
        }

        return new Collection($step_families);
    }
998320
public function getBUpdateExecutor($family)
    {
        if(!array_key_exists($family, $this->updateExecutorsB))
        {
            throw new CoreException('Исполнитель изменений (update executor) агрегатных(B) типов пакета '.$family.' не найдена в медиаторе!');
        }

        return $this->updateExecutorsB[$family];
    }
231257
public function getCDestructor($family)
    {
        if(!array_key_exists($family, $this->destructorsC))
        {
            throw new CoreException('Деструктор простых(C) типов пакета '.$family.' не найдена в медиаторе!');
        }

        return $this->destructorsC[$family];
    }