Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Mapping.php

function Mapping::getOptionalKeys

Gets all optional keys in this mapping.

Return value

string[] A list of optional keys given the values in this mapping.

File

core/lib/Drupal/Core/Config/Schema/Mapping.php, line 206

Class

Mapping
Defines a mapping configuration element.

Namespace

Drupal\Core\Config\Schema

Code

public function getOptionalKeys() : array {
    return array_values(array_diff($this->getValidKeys(), $this->getRequiredKeys()));
}
RSS feed
Powered by Drupal