You are here

public function PhantomJSCaptureHelper::binaryExists in PhantomJS Capture 8

Check that the binary exists at the path that was given.

Parameters

$path:

Return value

bool

Overrides PhantomJSCaptureHelperInterface::binaryExists

2 calls to PhantomJSCaptureHelper::binaryExists()
PhantomJSCaptureHelper::capture in src/PhantomJSCaptureHelper.php
Captures a screen shot using PhantomJS by calling the program.
PhantomJSCaptureHelper::getVersion in src/PhantomJSCaptureHelper.php
Return the version of PhantomJS binary on the server.

File

src/PhantomJSCaptureHelper.php, line 52

Class

PhantomJSCaptureHelper

Namespace

Drupal\phantomjs_capture

Code

public function binaryExists($path) {
  if (is_null($path) || !file_exists($path)) {
    throw new FileNotFoundException($path);
  }
  return TRUE;
}