public function work($os)
    {
        switch ($os) {
            case 'linux':
                $this->_fetchPciIdsLinux();
                $this->_fetchUsbIdsLinux();
            break;
            case 'freebsd':
            case 'dragonfly':
                $this->_fetchPciIdsPciConf();
            break;
            default:
                return;
            break;
        }
        $worthiness = $this->_is_cache_worthy();
        $save_cache = false;
        if (!$worthiness['pci']) {
            $save_cache = true;
            $this->_fetchPciNames();
        } else {
            $this->_pci_devices = isset($this->_existing_cache_vals['hw']['pci']) ? $this->_existing_cache_vals['hw']['pci'] : [];
        }
        if (!$worthiness['usb']) {
            $save_cache = true;
            $this->_fetchUsbNames();
        } else {
            $this->_usb_devices = isset($this->_existing_cache_vals['hw']['usb']) ? $this->_existing_cache_vals['hw']['usb'] : [];
        }
        if ($save_cache) {
            $this->_write_cache();
        }
    }
public function work($os)
    {
        switch ($os) {
            case 'linux':
                $this->_fetchPciIdsLinux();
                $this->_fetchUsbIdsLinux();
            break;
            case 'freebsd':
            case 'dragonfly':
                $this->_fetchPciIdsPciConf();
            break;
            default:
                return;
            break;
        }
        $worthiness = $this->_is_cache_worthy();
        $save_cache = false;
        if (!$worthiness['pci']) {
            $save_cache = true;
            $this->_fetchPciNames();
        } else {
            $this->_pci_devices = isset($this->_existing_cache_vals['hw']['pci']) ? $this->_existing_cache_vals['hw']['pci'] : [];
        }
        if (!$worthiness['usb']) {
            $save_cache = true;
            $this->_fetchUsbNames();
        } else {
            $this->_usb_devices = isset($this->_existing_cache_vals['hw']['usb']) ? $this->_existing_cache_vals['hw']['usb'] : [];
        }
        if ($save_cache) {
            $this->_write_cache();
        }
    }
public function work ( $ os ) { switch ( $ os ) { case 'linux' : $ this -> _fetchPciIdsLinux ( ) ; $ this -> _fetchUsbIdsLinux ( ) ; break ; case 'freebsd' : case 'dragonfly' : $ this -> _fetchPciIdsPciConf ( ) ; break ; default : return ; break ; } $ worthiness = $ this -> _is_cache_worthy ( ) ; $ save_cache = false ; if ( ! $ worthiness [ 'pci' ] ) { $ save_cache = true ; $ this -> _fetchPciNames ( ) ; } else { $ this -> _pci_devices = isset ( $ this -> _existing_cache_vals [ 'hw' ] [ 'pci' ] ) ? $ this -> _existing_cache_vals [ 'hw' ] [ 'pci' ] : [ ] ; } if ( ! $ worthiness [ 'usb' ] ) { $ save_cache = true ; $ this -> _fetchUsbNames ( ) ; } else { $ this -> _usb_devices = isset ( $ this -> _existing_cache_vals [ 'hw' ] [ 'usb' ] ) ? $ this -> _existing_cache_vals [ 'hw' ] [ 'usb' ] : [ ] ; } if ( $ save_cache ) { $ this -> _write_cache ( ) ; } }
Do its goddam job.
@param $os
Do its goddam job .