original_string: protected function getPluginMetas(PluginInterface $plugin)
      {
          $metas = $plugin->getMetas();
  
          if (is_array($metas) === false) {
              $classname = get_class($plugin);
  
              throw new \RuntimeException(sprintf('Expected an array at method "getMetas" of the plugin: "%s".', $classname));
          }
  
          $metas = $this->resolver->resolve($metas);
  
          if (empty($metas['name']) === true) {
              $metas['name'] = get_class($plugin);
          }
  
          return $metas;
      }
code: protected function getPluginMetas(PluginInterface $plugin)
      {
          $metas = $plugin->getMetas();
  
          if (is_array($metas) === false) {
              $classname = get_class($plugin);
  
              throw new \RuntimeException(sprintf('Expected an array at method "getMetas" of the plugin: "%s".', $classname));
          }
  
          $metas = $this->resolver->resolve($metas);
  
          if (empty($metas['name']) === true) {
              $metas['name'] = get_class($plugin);
          }
  
          return $metas;
      }
code_tokens: protected function getPluginMetas ( PluginInterface $ plugin ) { $ metas = $ plugin -> getMetas ( ) ; if ( is_array ( $ metas ) === false ) { $ classname = get_class ( $ plugin ) ; throw new \ RuntimeException ( sprintf ( 'Expected an array at method "getMetas" of the plugin: "%s".' , $ classname ) ) ; } $ metas = $ this -> resolver -> resolve ( $ metas ) ; if ( empty ( $ metas [ 'name' ] ) === true ) { $ metas [ 'name' ] = get_class ( $ plugin ) ; } return $ metas ; }
docstring: Gets metas of a plugin.
  
  @param string          $filename The plugin filename
  @param PluginInterface $plugin   The plugin
  
  @return array
  
  @throws RuntimeException If bad metas
docstring_tokens: Gets metas of a plugin .