setOffset() public method

Set the offset to start limiting from
public setOffset ( integer $offset )
$offset integer Offset to seek to and begin byte limiting from
Esempio n. 1
0
 /**
  * @expectedException \RuntimeException
  * @expectedExceptionMessage Could not seek to stream offset 2
  */
 public function testThrowsWhenCurrentGreaterThanOffsetSeek()
 {
     $a = Psr7\stream_for('foo_bar');
     $b = new NoSeekStream($a);
     $c = new LimitStream($b);
     $a->getContents();
     $c->setOffset(2);
 }