示例#1
0
 /**
  * Normalizes and validates a sequence of path atoms.
  *
  * This method is called internally by the constructor upon instantiation.
  * It can be overridden in child classes to change how path atoms are
  * normalized and/or validated.
  *
  * @param mixed<string> $atoms The path atoms to normalize.
  *
  * @return array<string>                                The normalized path atoms.
  * @throws Exception\EmptyPathAtomException             If any path atom is empty.
  * @throws Exception\PathAtomContainsSeparatorException If any path atom contains a separator.
  */
 protected function normalizeAtoms($atoms)
 {
     $atoms = parent::normalizeAtoms($atoms);
     if (count($atoms) < 1) {
         throw new Exception\EmptyPathException();
     }
     return $atoms;
 }