You are here

public function S3fsStreamWrapper::stream_read in S3 File System 7.2

Same name and namespace in other branches
  1. 7 S3fsStreamWrapper.inc \S3fsStreamWrapper::stream_read()

Support for fread(), file_get_contents() etc.

Parameters

int $count: Maximum number of bytes to be read.

Return value

string The data which was read from the stream, or FALSE in case of an error.

Overrides StreamWrapperInterface::stream_read

See also

http://php.net/manual/en/streamwrapper.stream-read.php

File

./S3fsStreamWrapper.inc, line 697
Drupal stream wrapper implementation for S3 File System.

Class

S3fsStreamWrapper
The stream wrapper class.

Code

public function stream_read($count) {
  $this
    ->_debug("stream_read({$count}) called for {$this->uri}.");
  return $this->body
    ->read($count);
}