Default category list. It can be overwritten by child classes.
Pay attention to the keys!

@return array
181704
protected function getCategories()
    {
        return array(
            array(
                'id' => 'environment',
                'label' => __('Environment'),
                'categories' => array(
                    array(
                        'id' => 'comfort',
                        'label' => __('Comfort')
                    ),
                    array(
                        'id' => 'disturbance',
                        'label' => __('Disturbance')
                    ),
                    array(
                        'id' => 'noise',
                        'label' => __('Noise')
                    ),
                    array(
                        'id' => 'powerOutage',
                        'label' => __('Power Outage')
                    ),
                    array(
                        'id' => 'weather',
                        'label' => __('Weather')
                    ),
                )
            ),
            array(
                'id' => 'examinee',
                'label' => __('Examinee'),
                'categories' => array(
                    array(
                        'id' => 'behaviour',
                        'label' => __('Behaviour')
                    ),
                    array(
                        'id' => 'complaint',
                        'label' => __('Complaint')
                    ),
                    array(
                        'id' => 'idAuthorization',
                        'label' => __('ID/Authorization')
                    ),
                    array(
                        'id' => 'illness',
                        'label' => __('Illness')
                    ),
                    array(
                        'id' => 'late',
                        'label' => __('Late')
                    ),
                    array(
                        'id' => 'navigation',
                        'label' => __('Navigation')
                    ),
                    array(
                        'id' => 'noShow',
                        'label' => __('No Show')
                    ),
                )
            ),
            array(
                'id' => 'proctorStaff',
                'label' => __('Proctor/Staff'),
                'categories' => array(
                    array(
                        'id' => 'behaviour',
                        'label' => __('Behaviour')
                    ),
                    array(
                        'id' => 'compliance',
                        'label' => __('Compliance')
                    ),
                    array(
                        'id' => 'error',
                        'label' => __('Error')
                    ),
                    array(
                        'id' => 'late',
                        'label' => __('Late')
                    ),
                    array(
                        'id' => 'noShow',
                        'label' => __('No Show')
                    ),
                )
            ),
            array(
                'id' => 'technical',
                'label' => __('Technical'),
                'categories' => array(
                    array(
                        'id' => 'freezing',
                        'label' => __('Freezing')
                    ),
                    array(
                        'id' => 'launching',
                        'label' => __('Launching')
                    ),
                    array(
                        'id' => 'network',
                        'label' => __('Network')
                    ),
                    array(
                        'id' => 'printing',
                        'label' => __('Printing')
                    ),
                    array(
                        'id' => 'testingWorkstation',
                        'label' => __('Testing Workstation')
                    ),
                )
            ),
            array(
                'id' => 'other',
                'label' => __('Other')
            )
        );
    }
1214916
public function getAllCategoryTreesAsArray()
    {
        $rootIds = $this->getAllRootIds();

        $trees = array();
        foreach ($rootIds as $rootId) {
            $trees[$rootId] = $this->getCategoryTreeAsArray($rootId);
        }

        return $trees;
    }
441613
public function query() : array
    {
        $categories = Category::where('parent_id', null)->with('allChildrenTerm')->get();
        $allCategories = collect();

        foreach ($categories as $category) {
            $allCategories = $allCategories->merge($this->getCategory($category));
        }

        return [
            'category' => $allCategories,
        ];
    }
755030
public function getDefaultEntities()
    {
        return [
            'blog_category' => [
                'entity_model' => 'Mirasvit\Blog\Model\ResourceModel\Category',
                'table'        => 'mst_blog_category_entity',
                'attributes'   => [
                    'name' => [
                        'type'   => 'varchar',
                        'label'  => 'Name',
                        'input'  => 'text',
                        'global' => ScopedAttributeInterface::SCOPE_STORE,
                    ],

                    'url_key' => [
                        'type'   => 'varchar',
                        'label'  => 'Url Key',
                        'input'  => 'text',
                        'global' => ScopedAttributeInterface::SCOPE_STORE,
                    ],

                    'status' => [
                        'type'   => 'int',
                        'label'  => 'Status',
                        'input'  => 'select',
                        'source' => 'Magento\Eav\Model\Entity\Attribute\Source\Boolean',
                        'global' => ScopedAttributeInterface::SCOPE_WEBSITE,
                    ],

                    'content' => [
                        'type'   => 'text',
                        'label'  => 'Content',
                        'input'  => 'textarea',
                        'global' => ScopedAttributeInterface::SCOPE_STORE,
                    ],

                    'meta_title'       => [
                        'type'   => 'varchar',
                        'label'  => 'Meta Title',
                        'input'  => 'text',
                        'global' => ScopedAttributeInterface::SCOPE_STORE,
                    ],
                    'meta_keywords'    => [
                        'type'   => 'text',
                        'label'  => 'Meta Keywords',
                        'input'  => 'textarea',
                        'global' => ScopedAttributeInterface::SCOPE_STORE,
                    ],
                    'meta_description' => [
                        'type'   => 'varchar',
                        'label'  => 'Meta Description',
                        'input'  => 'textarea',
                        'global' => ScopedAttributeInterface::SCOPE_STORE,
                    ],
                ],
            ],
        ];
    }
433447
protected function getProcessedCategoryIds()
    {
        $categoryIds = [];
        $source = $this->getSource();

        $source->rewind();
        while ($source->valid()) {
            $current = $source->current();
            if (isset($this->newCategory[$current[self::COL_ROOT]][$current[self::COL_CATEGORY]])) {
                $categoryIds[] = $this->newCategory[$current[self::COL_ROOT]][$current[self::COL_CATEGORY]];
            } elseif (isset($this->categoriesWithRoots[$current[self::COL_ROOT]][$current[self::COL_CATEGORY]])) {
                $categoryIds[] = $this->categoriesWithRoots[$current[self::COL_ROOT]][$current[self::COL_CATEGORY]];
            }

            $source->next();
        }

        return $categoryIds;
    }
1062735
public function get_parent_category() {
        if ($this->is_category_item() or $this->is_course_item()) {
            return $this->get_item_category();

        } else {
            return grade_category::fetch(array('id'=>$this->categoryid));
        }
    }
1038089
public function getList()
    {
        $category = $this->getCategory();

        $list = $this->getCategoryConfig($category);

        foreach ($list as $context => $config) {
            $list[$context] = $this->getAll($context);
        }

        return $list;
    }
892148
public function getDefaultSorting()
    {
        $aSorting = parent::getDefaultSorting();

        $oCategory = $this->getActiveCategory();

        if ($this->getListType() != 'search' && $oCategory && $oCategory instanceof \OxidEsales\Eshop\Application\Model\Category) {
            if ($sSortBy = $oCategory->getDefaultSorting()) {
                $sSortDir = ($oCategory->getDefaultSortingMode()) ? "desc" : "asc";
                $aSorting = ['sortby' => $sSortBy, 'sortdir' => $sSortDir];
            }
        }

        return $aSorting;
    }
441669
public function getCategoriesList()
    {
        $list = [];
        
        foreach($this->Categories() as $cat) {
            $list[] = $cat->FullHierarchy;
        }

        return implode(", ", $list);
    }
673594
private function getCurrentCategory()
    {
        $category = false;

        if ($this->registry->registry('current_category') && $this->registry->registry('current_category')->getId()) {
            $category = $this->registry->registry('current_category');
        }

        return $category;
    }
793774
public function getDefaultSorting()
    {
        $sorting = parent::getDefaultSorting();
        $activeCategory = $this->getActiveCategory();

        if ($this->getListType() != 'search' && $activeCategory && $activeCategory instanceof \OxidEsales\Eshop\Application\Model\Category) {
            if ($categorySorting = $activeCategory->getDefaultSorting()) {
                $sortingDirection = ($activeCategory->getDefaultSortingMode()) ? "desc" : "asc";
                $sorting = ['sortby' => $categorySorting, 'sortdir' => $sortingDirection];
            }
        }

        return $sorting;
    }
254242
public function dontShowEmptyCategories()
    {
        if ($this->_blDontShowEmptyCats == null) {
            $this->_blDontShowEmptyCats = false;
            if ($dontShowEmptyCats = \OxidEsales\Eshop\Core\Registry::getConfig()->getConfigParam('blDontShowEmptyCategories')) {
                $this->_blDontShowEmptyCats = $dontShowEmptyCats;
            }
        }

        return $this->_blDontShowEmptyCats;
    }
643935
public function getVatClasses()
    {
        $result = array();
        /** @var \hikashopCategoryClass $categoryClass */
        $categoryClass = hikashop_get('class.category');
        /** @var \stdClass $category */
        $category = $categoryClass->get('tax');
        $taxClasses = $categoryClass->getChildren((int) $category->category_id, true, array(), '', 0, 0);
        foreach ($taxClasses as $taxClass) {
            /** @var \stdClass $category */
            $result[$taxClass->category_namekey] = $taxClass->category_name;
        }
        return $result;
    }
573237
public function getSchemaDataDefaults()
    {
        $defaults = parent::getSchemaDataDefaults();
        $children = $this->getChildren();
        if ($children && $children->count()) {
            $childSchema = [];
            /** @var FormField $child */
            foreach ($children as $child) {
                $childSchema[] = $child->getSchemaData();
            }
            $defaults['children'] = $childSchema;
        }

        $defaults['data']['tag'] = $this->getTag();
        $defaults['data']['legend'] = $this->getLegend();

        // Scaffolded children will inherit this data
        $defaults['data']['inherited'] = [
            'data' => [
                'fieldholder' => 'small'
            ],
        ];

        return $defaults;
    }
745198
protected function getDefaults() {
        if (!$this->_defaults) {
            $this->_defaults = new DefaultsList($this->version, $this->solution['sid']);
        }

        return $this->_defaults;
    }
970297
private function getCategoryCollection()
    {
        $categoryCollection = null;

        $suggestedTerms = $this->getSuggestedTerms();
        $terms          = [$this->queryFactory->get()->getQueryText()];

        if (!empty($suggestedTerms)) {
            $terms = array_merge($terms, $suggestedTerms);
        }

        $categoryCollection = $this->categoryCollectionFactory->create();
        $categoryCollection->addAttributeToSelect("is_active");
        $categoryCollection->setSearchQuery($terms);
        $categoryCollection->setPageSize($this->getResultsPageSize());

        return $categoryCollection;
    }
809873
public function getDefaultSorting()
    {
        $sorting = parent::getDefaultSorting();

        $category = $this->getActiveCategory();
        if ($category && $category instanceof \OxidEsales\Eshop\Application\Model\Category) {
            if ($defaultSorting = $category->getDefaultSorting()) {
                $articleViewName = getViewName('oxarticles');
                $sortBy = $articleViewName . '.' . $defaultSorting;
                $sortDirection = ($category->getDefaultSortingMode()) ? "desc" : "asc";
                $sorting = ['sortby' => $sortBy, 'sortdir' => $sortDirection];
            }
        }

        return $sorting;
    }