Lines Matching refs:this

35         $this->dispatcher = $dispatcher ?: new WebDriverDispatcher();
36 if (!$this->dispatcher->getDefaultDriver()) {
37 $this->dispatcher->setDefaultDriver($this);
39 $this->driver = $driver;
47 return $this->dispatcher;
55 return $this->driver;
61 * @return $this
65 $this->dispatch('beforeNavigateTo', $url, $this);
68 $this->driver->get($url);
70 $this->dispatchOnException($exception);
73 $this->dispatch('afterNavigateTo', $url, $this);
75 return $this;
85 $this->dispatch('beforeFindBy', $by, null, $this);
89 foreach ($this->driver->findElements($by) as $element) {
90 $elements[] = $this->newElement($element);
93 $this->dispatchOnException($exception);
97 $this->dispatch('afterFindBy', $by, null, $this);
109 $this->dispatch('beforeFindBy', $by, null, $this);
112 $element = $this->newElement($this->driver->findElement($by));
114 $this->dispatchOnException($exception);
118 $this->dispatch('afterFindBy', $by, null, $this);
131 if (!$this->driver instanceof JavaScriptExecutor) {
137 $this->dispatch('beforeScript', $script, $this);
140 $result = $this->driver->executeScript($script, $arguments);
142 $this->dispatchOnException($exception);
146 $this->dispatch('afterScript', $script, $this);
159 if (!$this->driver instanceof JavaScriptExecutor) {
165 $this->dispatch('beforeScript', $script, $this);
168 $result = $this->driver->executeAsyncScript($script, $arguments);
170 $this->dispatchOnException($exception);
173 $this->dispatch('afterScript', $script, $this);
180 * @return $this
185 $this->driver->close();
187 return $this;
189 $this->dispatchOnException($exception);
201 return $this->driver->getCurrentURL();
203 $this->dispatchOnException($exception);
215 return $this->driver->getPageSource();
217 $this->dispatchOnException($exception);
229 return $this->driver->getTitle();
231 $this->dispatchOnException($exception);
243 return $this->driver->getWindowHandle();
245 $this->dispatchOnException($exception);
257 return $this->driver->getWindowHandles();
259 $this->dispatchOnException($exception);
270 $this->driver->quit();
272 $this->dispatchOnException($exception);
285 return $this->driver->takeScreenshot($save_as);
287 $this->dispatchOnException($exception);
301 return $this->driver->wait($timeout_in_second, $interval_in_millisecond);
303 $this->dispatchOnException($exception);
315 return $this->driver->manage();
317 $this->dispatchOnException($exception);
330 $this->driver->navigate(),
331 $this->getDispatcher()
334 $this->dispatchOnException($exception);
346 return $this->driver->switchTo();
348 $this->dispatchOnException($exception);
360 return $this->driver->getTouch();
362 $this->dispatchOnException($exception);
370 return $this->driver->execute($name, $params);
372 $this->dispatchOnException($exception);
383 return new EventFiringWebElement($element, $this->getDispatcher());
392 if (!$this->dispatcher) {
396 $this->dispatcher->dispatch($method, $arguments);
404 $this->dispatch('onException', $exception, $this);