The parent container of all modals, this is where you initialze your modal.
@return \Zend\View\Model\ViewModel
489241
public function renderToolStyleModalContainerAction()
    {

        $id = $this->params()->fromQuery('id');
        $view = new ViewModel();
        $melisKey = $this->params()->fromRoute('melisKey', '');
        $view->melisKey = $melisKey;
        $view->id = $id;
        return $view;
    }
1222689
public function bootstrap(): self
    {
        if (!$this->info->installMode()) {
            $this->getApplicationInitializer()->init($this);
            $this->emit('system.init');

            return $this;
        }

        $manager = $this->moduleManager();

        /** @var Module|null $installer */
        $installer = null;

        foreach ($manager->modules() as $module) {
            if ($module->isApplicationInstaller()) {
                if ($installer !== null) {
                    $formatText = '%s was defined as an application installer before %s';
                    $formatArgs = [$installer->name(), $module->name()];
                    throw new \RuntimeException(vsprintf($formatText, $formatArgs));
                }

                $installer = $module;
            }
        }

        if ($installer === null) {
            throw new \RuntimeException("No application installer was found");
        }

        $enabled = [$installer->name() => Module::ENABLED];

        foreach ($manager->recursiveDependencies($installer) as $module) {
            $enabled[$module->name()] = Module::ENABLED;
        }

        $this->getApplicationInitializer()->init($this);
        $manager->setStatusList($enabled);

        $this->emit('system.init');

        return $this;
    }
355077
public function loadModalContent()
	{
		global $objPage;

		$id = \Input::get('modal');

		if($id == '')
		{
			return;
		}

		$page = \Input::get('page');

		// load layout because we need to initiate bootstrap
		/** @var \PageModel $objPage */
		$objPage = \PageModel::findByPk($page);
		$objPage->loadDetails();

		if($objPage === null)
		{
			$this->log(sprintf('Page ID %s not found', $page), 'Netzmacht\Bootstrap\Ajax::loadModalContent', TL_ERROR);
			exit;
		}

		$objLayout = $this->getPageLayout($objPage);

		// Set the layout template and template group
		$objPage->template = $objLayout->template ?: 'fe_page';
		$objPage->templateGroup = $objLayout->getRelated('pid')->templates;

		// trigger getPageLayout hook so
		if(isset($GLOBALS['TL_HOOKS']['getPageLayout']) && is_array($GLOBALS['TL_HOOKS']['getPageLayout']))
		{
			foreach($GLOBALS['TL_HOOKS']['getPageLayout'] as $hook)
			{
				$this->import($hook[0]);
				$this->{$hook[0]}->{$hook[1]}($objPage, $objLayout, $this);
			}
		}

		$model = \ModuleModel::findOneBy('type="bootstrap_modal" AND tl_module.id', $id);

		if($model === null)
		{
			exit;
		}

		$model->isAjax = true;
		$this->output($this->getFrontendModule($model));
	}
929468
public function getParentMap()
    {
        if (null !== $this->parentMap) {
            return $this->parentMap;
        }

        return $this->parentMap = $this->buildParentMap();
    }
1334797
protected function magic_get_flatnav() {
        if ($this->_flatnav === null) {
            $this->_flatnav = new flat_navigation($this);
            $this->_flatnav->initialise();
        }
        return $this->_flatnav;
    }
2699
public function toolModalCodeContainerAction()
    {
        $id = $this->params()->fromRoute('id', $this->params()->fromQuery('id', ''));

        $melisKey = $this->getMelisKey();

        $view = new ViewModel();
        $view->setTerminal(false);
        $view->melisKey = $melisKey;
        $view->id = $id;

        return $view;
    }
1134103
protected function Init()
    {
        $this->repeater = ContentRepeater::Schema()->ByContent($this->content);
        $this->current = $this->tree->FirstChildOf($this->item);
        $this->isEmpty = !$this->current;
        return parent::Init();
    }
352127
public function getParent()
    {
        if ($this->parent === null) {
            $this->setParent($this->groupParameterRepository->getByChild($this));
        }
        return $this->parent;
    }
569648
public function getParent()
    {
        if (($this->parent === null) && $this->getParentId()) {
            $this->parent = $this->termFactory->create($this->getParentId(), $this->taxonomy);
        }

        return $this->parent;
    }
595736
protected function getContainer()
    {
        if (!$this->objectStore) {
            $this->objectStore = $this->objectStoreFactory->getObjectStore();
        }

        return parent::getContainer();
    }
256636
public function getContainer() {
		if(!$this->container) {
			$this->container = $this->buildContainer();
			$this->container['kernel'] = $this;
		}
		return $this->container;
	}
239743
function initialize()
    {
        if ($this->isInitialize())
            return $this;

        // ) Load Modules ------------------------------------------------------\
        $serviceManager = $this->getServiceManager();
        /** @var ModuleManager $moduleManager */
        $moduleManager  = $serviceManager->get('ModuleManager');
        $moduleManager->loadModules();

        // ) Attach Listeners To Events ----------------------------------------\
        $events = $this->getEventManager();
        foreach ($this->listeners as $listener) {
            if (!is_object($listener)) {
                if (class_exists($listener))
                    $listener = new $listener();
                else
                    $listener = $this->getServiceManager()->get($listener);
            }

            if (!$listener instanceof ListenerAggregateInterface)
                throw new \Exception(sprintf(
                    'Listener must instance of "ListenerAggregateInterface" but "%s" given.'
                    , is_object($listener) ? get_class($listener) : gettype($listener)
                ));

            // Attach Aggregate Listener
            $events->attach($listener);
        }

        // Ci) Bootstrap Application --------------------------------------------\
        $this->bootstrap();

        $this->__isInitialize = true;

        return $this;
    }
259694
public function getLocalOrParentInitMethod()
    {
        $method = $this->getInitMethod();
        if ($method) {
            $parentClassDefinition = $this->getExtendsClassDefinition();
            if ($parentClassDefinition instanceof self) {
                $method = $parentClassDefinition->getInitMethod();
                if ($method) {
                    $this->addInitMethod($method->getStatementsBlock());
                }
            }
        }

        return $method;
    }
136054
public function init()
    {
        $config = new Config($this->getSetting('config'), $this->getEnvironment());

        $this->container = (new Container)
            ->setConfig($config)
            ->setInstance('core', $this)
            ->setInstance('config', $config);

        $services = $this->loadServices();
        $this->container->setServices($services);

        $this->modules = $this->loadModules();
        $this->loadRoutesAndServices();

        $this->router = (new Router($this->routes, $this->modules))
            ->setRequest($this->request)
            ->setBasePath($this->request->getBasePath());

        $this->container->addServices($this->services)
            ->setInstance('router', $this->router);

        foreach ($this->modules as $module) {
            $module->setContainer($this->container);
        }

        return $this;
    }
1302038
protected function Init()
    {
        $this->articles = array();
        $this->articleList = ContentArticleList::Schema()->ByContent($this->Content());
        $this->articlesTotal = 0;
        $this->InitArticles();
        return parent::Init();
    }
1318967
public function parent()
    {
        $p = $this->_parent();
        return $p ? new self($this->doc, $p) : null;
    }
679918
function getViewModel() {
		if ($this->useCache) {
			$viewModel = $this->recacheAgent->getViewModel('list', $this->entityNamespace, '');
			if ($viewModel) {
				return $viewModel;
			}
		}
		
		$this->viewModel = new ViewModel();
		
		$entities = $this->objectManager->getRepository($this->entityNamespace)->findBy($this->criteria);
		
		$entitiesData = [];
		foreach ($entities as $entity) {
			$entityData = $this->getEntityData($entity->getId());
			if ($entityData !== false && $entityData !== null) {
				$entitiesData[$entity->getId()] = $entityData;
			}
		}
		
		$this->viewModel->setVariable('entitiesData', $entitiesData);
		
		$this->viewModel->setVariable('entityProperties', $this->getEntityProperties());
		
		if ($this->listIcons === null) {
			$this->listIcons = ['show' => '', 'edit' => '', 'delete' => ''];
		}
		$this->viewModel->setVariable('listIcons', $this->listIcons);
		$this->viewModel->setVariable('listHeadIcons', $this->listHeadIcons);
		
		$this->setupTemplate();
		$this->setupTitle();
		
		if ($this->useCache) {
			$this->recacheAgent->storeViewModel($this->viewModel, 'list', $this->entityNamespace, '');
		}
		
		return $this->viewModel;
	}