Returns the authors that can publish to the given section.

@param Section $section
@return User[]
9456
private function _getSectionAuthorOptions(Section $section): array
    {
        $authors = User::find()
            ->can('createEntries:'.$section->uid)
            ->all();
        return $this->_formatAuthorOptions($authors);
    }
804204
protected function getSectionStructureFromIncomingStructure($section)
    {
        $pos = strpos($section, '.');
        if ($pos === false) {
            $section = (int) $section;
            if ($section === 0) {
                return $this->structure;
            }

            return $this->structure->parts[($section - 1)];
        }
        $sections = explode('.', $section);
        $count = count($sections);
        $outObject = null;
        foreach ($sections as $section) {
            $section = (int) $section;
            if (!isset($outObject)) {
                $outObject = $this->getObjectStructureFromParts($this->structure, ($section - 1));
            } else {
                $outObject = $this->getObjectStructureFromParts($outObject, ($section - 1));
            }
        }

        return $outObject;
    }
383386
public function get_contributors()
	{
		$contributors = array();
		foreach ((array) $this->get_item_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'contributor') as $contributor)
		{
			$name = null;
			$uri = null;
			$email = null;
			if (isset($contributor['child'][SIMPLEPIE_NAMESPACE_ATOM_10]['name'][0]['data']))
			{
				$name = $this->sanitize($contributor['child'][SIMPLEPIE_NAMESPACE_ATOM_10]['name'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
			}
			if (isset($contributor['child'][SIMPLEPIE_NAMESPACE_ATOM_10]['uri'][0]['data']))
			{
				$uri = $this->sanitize($contributor['child'][SIMPLEPIE_NAMESPACE_ATOM_10]['uri'][0]['data'], SIMPLEPIE_CONSTRUCT_IRI, $this->get_base($contributor['child'][SIMPLEPIE_NAMESPACE_ATOM_10]['uri'][0]));
			}
			if (isset($contributor['child'][SIMPLEPIE_NAMESPACE_ATOM_10]['email'][0]['data']))
			{
				$email = $this->sanitize($contributor['child'][SIMPLEPIE_NAMESPACE_ATOM_10]['email'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
			}
			if ($name !== null || $email !== null || $uri !== null)
			{
				$contributors[] = $this->registry->create('Author', array($name, $uri, $email));
			}
		}
		foreach ((array) $this->get_item_tags(SIMPLEPIE_NAMESPACE_ATOM_03, 'contributor') as $contributor)
		{
			$name = null;
			$url = null;
			$email = null;
			if (isset($contributor['child'][SIMPLEPIE_NAMESPACE_ATOM_03]['name'][0]['data']))
			{
				$name = $this->sanitize($contributor['child'][SIMPLEPIE_NAMESPACE_ATOM_03]['name'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
			}
			if (isset($contributor['child'][SIMPLEPIE_NAMESPACE_ATOM_03]['url'][0]['data']))
			{
				$url = $this->sanitize($contributor['child'][SIMPLEPIE_NAMESPACE_ATOM_03]['url'][0]['data'], SIMPLEPIE_CONSTRUCT_IRI, $this->get_base($contributor['child'][SIMPLEPIE_NAMESPACE_ATOM_03]['url'][0]));
			}
			if (isset($contributor['child'][SIMPLEPIE_NAMESPACE_ATOM_03]['email'][0]['data']))
			{
				$email = $this->sanitize($contributor['child'][SIMPLEPIE_NAMESPACE_ATOM_03]['email'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
			}
			if ($name !== null || $email !== null || $url !== null)
			{
				$contributors[] = $this->registry->create('Author', array($name, $url, $email));
			}
		}

		if (!empty($contributors))
		{
			return array_unique($contributors);
		}
		else
		{
			return null;
		}
	}
721625
public function section_availability($section) {
        $context = context_course::instance($section->course);
        $canviewhidden = has_capability('moodle/course:viewhiddensections', $context);
        return html_writer::div($this->section_availability_message($section, $canviewhidden), 'section_availability');
    }
1266753
public function section(string $section, array $default = []): array
    {
        if (isset($this->propertyData[$section])) {
            return $this->propertyData[$section];
        }

        return $default;
    }
364538
public function removeSection($section)
    {
        if ($has = $this->hasSection($section)) {
            unset($this->sections[$section]);
        }

        return $has;
    }
57042
public function getCandidateAuthors()
    {
        if ($this->config()->get('restrict_authors_to_group')) {
            return Group::get()->filter('Code', $this->config()->get('restrict_authors_to_group'))->first()->Members();
        }

        $list = Member::get();
        $this->extend('updateCandidateAuthors', $list);
        return $list;
    }
1067701
public function getSectionUrls(string $section, array $criteria = [], $siteId = null): array
    {
        $criteria = array_merge([
            'section' => $section,
            'status' => 'enabled',
        ], $criteria);

        return $this->getElementUrls(Entry::class, $criteria, $siteId);
    }
588460
public function get_authors() {
		$authors = array();

		$url = $this->get_value('http://purl.org/ontology/bibo/authorList');
		$info = $this->data[$url];
		foreach ($info as $k => $v) {
			if (strpos($k, '#type') !== false) {
				continue;
			}

			$authors[] = $this->get_author($v[0]['value']);
		}

		return $authors;
	}
370121
private function createValidatorsFromSection($sectionName, $section)
    {
        $validators = array();
        foreach ($section as $type => $content) {
            if ($validator = $this->createValidator($sectionName, $type, $content)) {
                $validators[] = $validator;
            }
        }

        return $validators;
    }
258521
public function getSectionComponents($sectionName)
    {
        return $this->getComponents()->filter(
            function (ComponentInterface $component) use ($sectionName) {
                return $component instanceof RenderableComponentInterface
                && $component->getRenderSection() === $sectionName;
            }
        );
    }
769315
public function getAuthors()
    {
        $authors = array();
        foreach ($this->xml->xpath('//AdministrativeMetadata/Property[@FormalName="author"]') as $author) {
            $authorName = $this->readName((string) $author['Value']);
            $authors[] = array(
                'firstname' => $authorName['firstname'],
                'lastname' => $authorName['lastname'],
                'email' => '',
                'link' => '',
            );
        }

        return implode(', ', $authors);
    }
1033724
public static function get_config($section = '') {

        $params = self::validate_parameters(self::get_config_parameters(), array('section' => $section));

        $settings = api::get_config($params['section']);
        $result['settings'] = array();
        foreach ($settings as $name => $value) {
            $result['settings'][] = array(
                'name' => $name,
                'value' => $value,
            );
        }

        $result['warnings'] = array();
        return $result;
    }
1340574
public function visitSection(SectionInterface $section)
    {

        $template = 'section/' . $section->getType() . '.twig';

        return $this
            ->loadTemplate($template)
            ->render(
                [
                    "id" => $section->getId(),
                    "classes" => $section->getClasses(),
                    "data" => $section->getData(),
                    "writables" => $section->getWritables(),
                ]
            );
    }
1181007
public function getSectionFields($section, $flatten = true)
    {
        if ($flatten === false) {
            $fields = $this->fields;
        } else {
            $fields = $this->getFlattenedFields();
        }

        $matchedFields = array();
        foreach ($fields as $fieldName => $field) {
            if (isset($field['options']['section']) && $field['options']['section'] == $section) {
                $matchedFields[$fieldName] = $field;
            }
        }

        return $matchedFields;
    }
476391
protected function getStyleDeps($section)
    {
        $dependencies = $this->getDependencies();
        $deps = isset($dependencies['styles']) ? $dependencies['styles'] : [];

        return isset($deps[$section]) ? $deps[$section] : [];
    }
58389
public function getSectionIdx($section)
    {
        if ($section instanceof \atk4\ui\AccordionSection) {
            return parent::getSectionIdx($section);
        }

        return parent::getSectionIdx($section->owner);
    }