public static function EasyRdf_Namespace::prefixOfUri

Return the prefix namespace that a URI belongs to.

Parameters

string $uri A full URI (eg 'http://xmlns.com/foaf/0.1/name'):

Return value

string The prefix namespace that it is a part of(eg 'foaf')

1 call to EasyRdf_Namespace::prefixOfUri()
EasyRdf_Resource::prefix in drupal/core/vendor/easyrdf/easyrdf/lib/EasyRdf/Resource.php
Get a the prefix of the namespace that this resource is part of

File

drupal/core/vendor/easyrdf/easyrdf/lib/EasyRdf/Namespace.php, line 294

Class

EasyRdf_Namespace
A namespace registry and manipulation class.

Code

public static function prefixOfUri($uri) {
  if ($parts = self::splitUri($uri)) {
    return $parts[0];
  }
}