Skip to content

Commit

Permalink
Fix method signatures #16
Browse files Browse the repository at this point in the history
  • Loading branch information
zbateson committed May 30, 2023
1 parent 56837bc commit 783b034
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 10 deletions.
4 changes: 2 additions & 2 deletions src/Base64Stream.php
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ public function getSize() : ?int
* @param int $whence
* @throws RuntimeException
*/
public function seek($offset, $whence = SEEK_SET)
public function seek($offset, $whence = SEEK_SET) : void
{
throw new RuntimeException('Cannot seek a Base64Stream');
}
Expand Down Expand Up @@ -148,7 +148,7 @@ private function fillBuffer(int $length) : void
* @param int $length
* @return string
*/
public function read($length)
public function read($length) : string
{
// let Guzzle decide what to do.
if ($length <= 0 || $this->eof()) {
Expand Down
4 changes: 2 additions & 2 deletions src/CharsetStream.php
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ public function getSize() : ?int
* @param int $whence
* @throws RuntimeException
*/
public function seek($offset, $whence = SEEK_SET)
public function seek($offset, $whence = SEEK_SET) : void
{
throw new RuntimeException('Cannot seek a CharsetStream');
}
Expand Down Expand Up @@ -146,7 +146,7 @@ public function eof() : bool
* @param int $length
* @return string
*/
public function read($length)
public function read($length) : string
{
// let Guzzle decide what to do.
if ($length <= 0 || $this->eof()) {
Expand Down
4 changes: 2 additions & 2 deletions src/PregReplaceFilterStream.php
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ public function eof() : bool
* @param int $whence
* @throws RuntimeException
*/
public function seek($offset, $whence = SEEK_SET)
public function seek($offset, $whence = SEEK_SET) : void
{
throw new RuntimeException('Cannot seek a PregReplaceFilterStream');
}
Expand Down Expand Up @@ -103,7 +103,7 @@ private function fillBuffer(int $length) : void
* @param int $length
* @return string
*/
public function read($length)
public function read($length) : string
{
$this->fillBuffer($length);
return $this->buffer->read($length);
Expand Down
2 changes: 1 addition & 1 deletion src/QuotedPrintableStream.php
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ public function getSize() : ?int
* @param int $whence
* @throws RuntimeException
*/
public function seek($offset, $whence = SEEK_SET)
public function seek($offset, $whence = SEEK_SET) : void
{
throw new RuntimeException('Cannot seek a QuotedPrintableStream');
}
Expand Down
4 changes: 2 additions & 2 deletions src/SeekingLimitStream.php
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ private function doSeek(int $pos) : void
* @param int $offset
* @param int $whence
*/
public function seek($offset, $whence = SEEK_SET)
public function seek($offset, $whence = SEEK_SET) : void
{
$pos = $offset;
switch ($whence) {
Expand Down Expand Up @@ -180,7 +180,7 @@ public function seekAndRead(int $length) : string
* @param int $length
* @return string
*/
public function read($length)
public function read($length) : string
{
$pos = $this->stream->tell();
$ret = $this->seekAndRead($length);
Expand Down
2 changes: 1 addition & 1 deletion src/UUStream.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ public function getSize() : ?int
* @param int $whence
* @throws RuntimeException
*/
public function seek($offset, $whence = SEEK_SET)
public function seek($offset, $whence = SEEK_SET) : void
{
throw new RuntimeException('Cannot seek a UUStream');
}
Expand Down

0 comments on commit 783b034

Please sign in to comment.