public function QuestionHelper::setInputStream in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/symfony/console/Helper/QuestionHelper.php \Symfony\Component\Console\Helper\QuestionHelper::setInputStream()
Sets the input stream to read from when interacting with the user.
This is mainly useful for testing purpose.
Parameters
resource $stream The input stream:
Throws
\InvalidArgumentException In case the stream is not a resource
File
- vendor/
symfony/ console/ Helper/ QuestionHelper.php, line 75
Class
- QuestionHelper
- The QuestionHelper class provides helpers to interact with the user.
Namespace
Symfony\Component\Console\HelperCode
public function setInputStream($stream) {
if (!is_resource($stream)) {
throw new \InvalidArgumentException('Input stream must be a valid resource.');
}
$this->inputStream = $stream;
}