original_string: public function getConfigurationSources(ConfigInterface $conf)
      {
          if ($conf->hasOption('config-file')) {
              $file = $conf->getOption('config-file');
              if (isset($file)) {
                  if (!strstr($file, '/')) {
                      $file = $conf->getOption('config-dir').$file;
                  }
  
                  return array($file);
              }
          }
          // load every xml file in config dir
          $dir = $conf->getOption('config-dir');
          $list = glob("{$dir}*.xml", GLOB_ERR);
          if ($list === false) {
              throw new IOException($dir, null,
                   "config-dir '$dir' is not readable",
                   IOException::FAILURE_NOT_READABLE);
          }
  
          return $list;
      }
code: public function getConfigurationSources(ConfigInterface $conf)
      {
          if ($conf->hasOption('config-file')) {
              $file = $conf->getOption('config-file');
              if (isset($file)) {
                  if (!strstr($file, '/')) {
                      $file = $conf->getOption('config-dir').$file;
                  }
  
                  return array($file);
              }
          }
          // load every xml file in config dir
          $dir = $conf->getOption('config-dir');
          $list = glob("{$dir}*.xml", GLOB_ERR);
          if ($list === false) {
              throw new IOException($dir, null,
                   "config-dir '$dir' is not readable",
                   IOException::FAILURE_NOT_READABLE);
          }
  
          return $list;
      }
code_tokens: public function getConfigurationSources ( ConfigInterface $ conf ) { if ( $ conf -> hasOption ( 'config-file' ) ) { $ file = $ conf -> getOption ( 'config-file' ) ; if ( isset ( $ file ) ) { if ( ! strstr ( $ file , '/' ) ) { $ file = $ conf -> getOption ( 'config-dir' ) . $ file ; } return array ( $ file ) ; } } // load every xml file in config dir $ dir = $ conf -> getOption ( 'config-dir' ) ; $ list = glob ( "{$dir}*.xml" , GLOB_ERR ) ; if ( $ list === false ) { throw new IOException ( $ dir , null , "config-dir '$dir' is not readable" , IOException :: FAILURE_NOT_READABLE ) ; } return $ list ; }
docstring: Finds the configured configuration sources.
  
  The config needs at least a valid config-dir or config-file
  option.
  
  @throw Xinc::Core::Exception::IOException
  
  @return array with configured sources
docstring_tokens: Finds the configured configuration sources .