| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148 |
- <?php
- /*
- * This file is part of the php-phantomjs.
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
- namespace JonnyW\PhantomJs\IO;
- use Psr\Http\Message\MessageInterface;
- /**
- * PHP PhantomJs.
- *
- * @author Jon Wenmoth <contact@jonnyw.me>
- */
- interface InputInterface extends MessageInterface
- {
- /**
- * Create new input with
- * added custom setting.
- *
- * @param string $name
- * @param mixed $value
- *
- * @return \JonnyW\PhantomJs\IO\InputInterface
- */
- public function withCustom($name, $value);
- /**
- * Create new input with
- * custom setting removed.
- *
- * @param string $name
- *
- * @return \JonnyW\PhantomJs\IO\InputInterface
- */
- public function withoutCustom($name);
- /**
- * Get custom setting.
- *
- * @param string $name
- *
- * @return mixed
- */
- public function getCustom($name);
-
- /**
- * Has cookie.
- *
- * @param string $cookie
- *
- * @return bool
- */
- public function hasCookie($cookie);
- /**
- * Get single added cookie.
- *
- * @param string $cookie
- *
- * @return \JonnyW\PhantomJs\Page\Cookie|null
- */
- public function getCookie($cookie);
- /**
- * Get all added cookies.
- *
- * @return array
- */
- public function getCookies();
- /**
- * Create new input with
- * added cookie.
- *
- * @param \JonnyW\PhantomJs\Page\Cookie $cookie
- *
- * @return \JonnyW\PhantomJs\IO\InputInterface
- */
- public function withCookie(Cookie $cookie);
- /**
- * Create new input with cookie
- * removed and flagged for delete.
- *
- * @param string $cookie
- *
- * @return \JonnyW\PhantomJs\IO\InputInterface
- */
- public function withoutCookie($cookie);
- /**
- * Has setting.
- *
- * @param string $setting
- *
- * @return bool
- */
- public function hasSetting($setting);
- /**
- * Get single setting.
- *
- * @param string $setting
- *
- * @return mixed
- */
- public function getSetting($setting);
- /**
- * Get all settings.
- *
- * @return array
- */
- public function getSettings();
- /**
- * Create new input with
- * added setting.
- *
- * @param string $setting
- * @param mixed $value
- *
- * @return \JonnyW\PhantomJs\IO\InputInterface
- */
- public function withSetting($setting, $value);
- /**
- * Create new input with setting
- * removed.
- *
- * @param string $setting
- *
- * @return \JonnyW\PhantomJs\IO\InputInterface
- */
- public function withoutSetting($setting);
- /**
- * Get input type.
- *
- * @return string
- */
- public function getType();
- }
|