original_string: protected function createScreenshot()
      {
          $image = imagecreatefromstring($this->webDriver->screenshotAsImage());
          if (false === $image) {
              throw new WebDriver_Exception("Invalid screenshot data");
          }
          return $image;
      }
code: protected function createScreenshot()
      {
          $image = imagecreatefromstring($this->webDriver->screenshotAsImage());
          if (false === $image) {
              throw new WebDriver_Exception("Invalid screenshot data");
          }
          return $image;
      }
code_tokens: protected function createScreenshot ( ) { $ image = imagecreatefromstring ( $ this -> webDriver -> screenshotAsImage ( ) ) ; if ( false === $ image ) { throw new WebDriver_Exception ( "Invalid screenshot data" ) ; } return $ image ; }
docstring: Takes screenshot and returns image resource.
  
  @return resource
  @throws WebDriver_Exception
docstring_tokens: Takes screenshot and returns image resource .