Pressbooks\Modules\Export\Prince\Pdf::hasDependencies PHP Method

hasDependencies() static public method

Dependency check.
static public hasDependencies ( ) : boolean
return boolean
    static function hasDependencies()
    {
        if (false !== \Pressbooks\Utility\check_prince_install() && false !== \Pressbooks\Utility\check_xmllint_install()) {
            return true;
        }
        return false;
    }

Usage Example

 /**
  * Returns a filtered array of tabs that we should be loading.
  * @returns array
  */
 static function getTabs()
 {
     $tabs = array('global' => '\\Pressbooks\\Modules\\ThemeOptions\\GlobalOptions', 'web' => '\\Pressbooks\\Modules\\ThemeOptions\\WebOptions', 'pdf' => '\\Pressbooks\\Modules\\ThemeOptions\\PDFOptions', 'mpdf' => '\\Pressbooks\\Modules\\ThemeOptions\\MPDFOptions', 'ebook' => '\\Pressbooks\\Modules\\ThemeOptions\\EbookOptions');
     if (!\Pressbooks\Modules\Export\Prince\Pdf::hasDependencies()) {
         unset($tabs['pdf']);
     }
     if (!\Pressbooks\Modules\Export\Mpdf\Pdf::hasDependencies()) {
         unset($tabs['mpdf']);
     }
     return apply_filters('pressbooks_theme_options_tabs', $tabs);
 }
All Usage Examples Of Pressbooks\Modules\Export\Prince\Pdf::hasDependencies