src/Vatsimphp/VatsimData.php
protected function prepareMetarSync()
    {
        if (!empty($this->metarSync)) {
            return $this->metarSync;
        }
        LoggerFactory::$file = $this->config['logFile'];
        LoggerFactory::$level = $this->config['logLevel'];
        $this->metarSync = $this->getMetarSync();
        $this->metarSync->setDefaults();
        $this->metarSync->cacheDir = $this->config['cacheDir'];
        $this->metarSync->cacheOnly = false;
        $this->metarSync->refreshInterval = $this->config['metarRefresh'];
        $this->metarSync->forceRefresh = $this->config['forceMetarRefresh'];
        $this->metarSync->registerUrlFromStatus($this->prepareSync(), 'metarUrls');

        return $this->metarSync;
    }
protected function prepareMetarSync()
    {
        if (!empty($this->metarSync)) {
            return $this->metarSync;
        }
        LoggerFactory::$file = $this->config['logFile'];
        LoggerFactory::$level = $this->config['logLevel'];
        $this->metarSync = $this->getMetarSync();
        $this->metarSync->setDefaults();
        $this->metarSync->cacheDir = $this->config['cacheDir'];
        $this->metarSync->cacheOnly = false;
        $this->metarSync->refreshInterval = $this->config['metarRefresh'];
        $this->metarSync->forceRefresh = $this->config['forceMetarRefresh'];
        $this->metarSync->registerUrlFromStatus($this->prepareSync(), 'metarUrls');

        return $this->metarSync;
    }
protected function prepareMetarSync ( ) { if ( ! empty ( $ this -> metarSync ) ) { return $ this -> metarSync ; } LoggerFactory :: $ file = $ this -> config [ 'logFile' ] ; LoggerFactory :: $ level = $ this -> config [ 'logLevel' ] ; $ this -> metarSync = $ this -> getMetarSync ( ) ; $ this -> metarSync -> setDefaults ( ) ; $ this -> metarSync -> cacheDir = $ this -> config [ 'cacheDir' ] ; $ this -> metarSync -> cacheOnly = false ; $ this -> metarSync -> refreshInterval = $ this -> config [ 'metarRefresh' ] ; $ this -> metarSync -> forceRefresh = $ this -> config [ 'forceMetarRefresh' ] ; $ this -> metarSync -> registerUrlFromStatus ( $ this -> prepareSync ( ) , 'metarUrls' ) ; return $ this -> metarSync ; }
Prepare MetarSync object for reusage.

@return MetarSync
Prepare MetarSync object for reusage .