PHP 8.3.31
Preview: BufferedConsoleOutput.php Size: 941 B
/home/getspomw/royalsquad.us/vendor/laravel/prompts/src/Output/BufferedConsoleOutput.php

<?php

namespace Laravel\Prompts\Output;

class BufferedConsoleOutput extends ConsoleOutput
{
    /**
     * The output buffer.
     */
    protected string $buffer = '';

    /**
     * Empties the buffer and returns its content.
     */
    public function fetch(): string
    {
        $content = $this->buffer;
        $this->buffer = '';

        return $content;
    }

    /**
     * Return the content of the buffer.
     */
    public function content(): string
    {
        return $this->buffer;
    }

    /**
     * Write to the output buffer.
     */
    protected function doWrite(string $message, bool $newline): void
    {
        $this->buffer .= $message;

        if ($newline) {
            $this->buffer .= \PHP_EOL;
        }
    }

    /**
     * Write output directly, bypassing newline capture.
     */
    public function writeDirectly(string $message): void
    {
        $this->doWrite($message, false);
    }
}

Directory Contents

Dirs: 0 × Files: 3

Name Size Perms Modified Actions
941 B lrw-rw-rw- 2025-09-17 06:52:54
Edit Download
1.16 KB lrw-rw-rw- 2025-09-17 06:52:54
Edit Download
2.00 KB lrw-r--r-- 2026-04-26 08:40:49
Edit Download

If ZipArchive is unavailable, a .tar will be created (no compression).