You are here

protected function LibraryDiscoveryParser::isValidUri in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/lib/Drupal/Core/Asset/LibraryDiscoveryParser.php \Drupal\Core\Asset\LibraryDiscoveryParser::isValidUri()

Determines if the supplied string is a valid URI.

2 calls to LibraryDiscoveryParser::isValidUri()
LibraryDiscoveryParser::buildByExtension in core/lib/Drupal/Core/Asset/LibraryDiscoveryParser.php
Parses and builds up all the libraries information of an extension.
LibraryDiscoveryParser::resolveThemeAssetPath in core/lib/Drupal/Core/Asset/LibraryDiscoveryParser.php
Ensures that a full path is returned for an overriding theme asset.

File

core/lib/Drupal/Core/Asset/LibraryDiscoveryParser.php, line 406
Contains \Drupal\Core\Asset\LibraryDiscoveryParser.

Class

LibraryDiscoveryParser
Parses library files to get extension data.

Namespace

Drupal\Core\Asset

Code

protected function isValidUri($string) {
  return count(explode('://', $string)) === 2;
}