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

Breadcrumb

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

function LazyOpenStream::__construct

Parameters

string $filename File to lazily open:

string $mode fopen mode to use when opening the stream:

Overrides StreamDecoratorTrait::__construct

File

vendor/guzzlehttp/psr7/src/LazyOpenStream.php, line 32

Class

LazyOpenStream
Lazily reads or writes to a file that is opened only after an IO operation take place on the stream.

Namespace

GuzzleHttp\Psr7

Code

public function __construct(string $filename, string $mode) {
    $this->filename = $filename;
    $this->mode = $mode;
    // unsetting the property forces the first access to go through
    // __get().
    unset($this->stream);
}

API Navigation

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