PathElement::getInfo

public PathElement::getInfo()

Returns the element properties for this element.

Return value

array An array of element properties. See \Drupal\Core\Render\ElementInfoManagerInterface::getInfo() for documentation of the standard properties of all elements, and the return value format.

Overrides Textfield::getInfo

File

core/lib/Drupal/Core/Render/Element/PathElement.php, line 36

Class

PathElement
Provides a matched path render element.

Namespace

Drupal\Core\Render\Element

Code

public function getInfo() {
  $info = parent::getInfo();
  $class = get_class($this);
  $info['#validate_path'] = TRUE;
  $info['#convert_path'] = self::CONVERT_ROUTE;
  $info['#element_validate'] = array(
    array($class, 'validateMatchedPath'),
  );
  return $info;
}
doc_Drupal
2016-10-29 09:33:22
Comments
Leave a Comment

Please login to continue.