public function getProfile($name) {
    $dirs = $this->config['profile.dirs'];
    foreach ($dirs as $dir) {
      if (!is_dir($dir) || !is_readable($dir)) {
        continue;
      }
      $filename = $dir . DIRECTORY_SEPARATOR . $name . '.profile';
      if (is_readable($filename)) {
        $content = file_get_contents($filename);
        $json = json_decode($content);
        return $json;
      }
    }
    throw new \Exception("Profile $name not found");
  }
public function getProfile($name) {
    $dirs = $this->config['profile.dirs'];
    foreach ($dirs as $dir) {
      if (!is_dir($dir) || !is_readable($dir)) {
        continue;
      }
      $filename = $dir . DIRECTORY_SEPARATOR . $name . '.profile';
      if (is_readable($filename)) {
        $content = file_get_contents($filename);
        $json = json_decode($content);
        return $json;
      }
    }
    throw new \Exception("Profile $name not found");
  }
public function getProfile ( $ name ) { $ dirs = $ this -> config [ 'profile.dirs' ] ; foreach ( $ dirs as $ dir ) { if ( ! is_dir ( $ dir ) || ! is_readable ( $ dir ) ) { continue ; } $ filename = $ dir . DIRECTORY_SEPARATOR . $ name . '.profile' ; if ( is_readable ( $ filename ) ) { $ content = file_get_contents ( $ filename ) ; $ json = json_decode ( $ content ) ; return $ json ; } } throw new \ Exception ( "Profile $name not found" ) ; }
Read the video profile in given profile directories

@param string $name Profile name
@return object Profile
@throws Exception
Read the video profile in given profile directories