← All docs

stream_bucket_new()

Creates a new bucket for use in a stream filter.

stream_bucket_new()

function stream_bucket_new(resource $stream, string $buffer): mixed

Creates a new bucket for use in a stream filter.

Parameters:

  • $stream (resource)
  • $buffer (string)

Returns: mixed

Availability

No examples yet — check examples/ and showcases/ for usage patterns.

Internals

For how stream_bucket_new is implemented in the compiler, see the internals page.