Mercurial > hg > isophonics-drupal-site
diff vendor/jcalderonzumba/gastonjs/src/Browser/BrowserPageTrait.php @ 0:4c8ae668cc8c
Initial import (non-working)
author | Chris Cannam |
---|---|
date | Wed, 29 Nov 2017 16:09:58 +0000 |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/vendor/jcalderonzumba/gastonjs/src/Browser/BrowserPageTrait.php Wed Nov 29 16:09:58 2017 +0000 @@ -0,0 +1,59 @@ +<?php + +namespace Zumba\GastonJS\Browser; + +/** + * Trait BrowserPageTrait + * @package Zumba\GastonJS\Browser + */ +trait BrowserPageTrait { + /** + * Gets the status code of the request we are currently in + * @return mixed + */ + public function getStatusCode() { + return $this->command('status_code'); + } + + /** + * Returns the body of the response to a given browser request + * @return mixed + */ + public function getBody() { + return $this->command('body'); + } + + /** + * Returns the source of the current page + * @return mixed + */ + public function getSource() { + return $this->command('source'); + } + + /** + * Gets the current page title + * @return mixed + */ + public function getTitle() { + return $this->command('title'); + } + + /** + * Resize the current page + * @param $width + * @param $height + * @return mixed + */ + public function resize($width, $height) { + return $this->command('resize', $width, $height); + } + + /** + * Resets the page we are in to a clean slate + * @return mixed + */ + public function reset() { + return $this->command('reset'); + } +}