Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. vfsStreamWrapper.php

function vfsStreamWrapper::stream_read

read the stream up to $count bytes

Parameters

int $count amount of bytes to read:

Return value

string

File

vendor/mikey179/vfsstream/src/main/php/org/bovigo/vfs/vfsStreamWrapper.php, line 431

Class

vfsStreamWrapper
Stream wrapper to mock file system requests.

Namespace

org\bovigo\vfs

Code

public function stream_read($count) {
    if (self::WRITEONLY === $this->mode) {
        return '';
    }
    if ($this->content
        ->isReadable(vfsStream::getCurrentUser(), vfsStream::getCurrentGroup()) === false) {
        return '';
    }
    return $this->content
        ->read($count);
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal