Author: Chris Corbyn
Inheritance: extends Swift_ByteStream_AbstractFilterableInputStream, implements Swift_FileStream
 /**
  * @test
  * @expectedException \Swift_IoException
  */
 public function shouldThrowExceptionOnConsecutiveRead()
 {
     $fbs = new \Swift_ByteStream_FileByteStream('does not exist');
     try {
         $fbs->read(100);
     } catch (\Swift_IoException $exc) {
         $fbs->read(100);
     }
 }
 public function __construct()
 {
     $filePath = tempnam(sys_get_temp_dir(), 'FileByteStream');
     if ($filePath === false) {
         throw new Swift_IoException('Failed to retrieve temporary file name.');
     }
     parent::__construct($filePath, true);
 }