Changeset View
Changeset View
Standalone View
Standalone View
src/applications/almanac/storage/AlmanacNamespace.php
Context not available. | |||||
} | } | ||||
public function getNameLength() { | public function getNameLength() { | ||||
return strlen($this->getName()); | return @strlen($this->getName()); | ||||
} | } | ||||
/** | /** | ||||
Context not available. | |||||
// For a name like "x.y.z", produce a list of controlling namespaces like | // For a name like "x.y.z", produce a list of controlling namespaces like | ||||
// ("z", "y.x", "x.y.z"). | // ("z", "y.x", "x.y.z"). | ||||
$names = array(); | $names = array(); | ||||
$parts = explode('.', $name); | $parts = @explode('.', $name); | ||||
for ($ii = 0; $ii < count($parts); $ii++) { | for ($ii = 0; $ii < count($parts); $ii++) { | ||||
$names[] = implode('.', array_slice($parts, -($ii + 1))); | $names[] = implode('.', array_slice($parts, -($ii + 1))); | ||||
} | } | ||||
Context not available. |
Content licensed under Creative Commons Attribution-ShareAlike 4.0 (CC-BY-SA) unless otherwise noted; code licensed under Apache 2.0 or other open source licenses. · CC BY-SA 4.0 · Apache 2.0