stream_get_contents

Supported Versions: PHP 5, PHP 7, PHP 8
Reads remainder of a stream into a string
<?php stream_get_contents(resource $stream, ?int $length = null, int $offset = -1): string|false
<?php             return null;

        }



        $value = is_resource($value) ? stream_get_contents($value) : $value;



        set_error_handler(function (int $code, string $message): bool {

            throw ConversionException::conversionFailedUnserialization($this->getName(), $message);
<?php         }



        if (is_resource($value)) {

            $value = stream_get_contents($value);

        }



        $val = json_decode($value, true);
<?php             return null;

        }



        $value = is_resource($value) ? stream_get_contents($value) : $value;



        set_error_handler(function (int $code, string $message): bool {

            throw ConversionException::conversionFailedUnserialization($this->getName(), $message);
<?php             return [];

        }



        $value = is_resource($value) ? stream_get_contents($value) : $value;



        return explode(',', $value);

    }
<?php     public function convertToPHPValue($value, AbstractPlatform $platform)

    {

        return is_resource($value) ? stream_get_contents($value) : $value;

    }
<?php         $blobValue = Type::getType('blob')->convertToPHPValue($rows[0], $this->connection->getDatabasePlatform());



        self::assertIsResource($blobValue);

        self::assertEquals($text, stream_get_contents($blobValue));

    }

}
<?php                 $this->connection->getDatabasePlatform()

            );



        self::assertSame($contents, stream_get_contents($stream));

    }



    public function testIncompletelyFetchedStatementDoesNotBlockConnection(): void
<?php         if (is_resource($value)) {

            $value = stream_get_contents($value);

        }



        return $value;
<?php         $phpValue      = $this->type->convertToPHPValue($databaseValue, $this->platform);



        self::assertIsResource($phpValue);

        self::assertEquals($databaseValue, stream_get_contents($phpValue));

    }



    public function testBinaryResourceConvertsToPHPValue(): void
<?php         $phpValue      = $this->type->convertToPHPValue($databaseValue, $this->platform);



        self::assertIsResource($phpValue);

        self::assertSame($databaseValue, stream_get_contents($phpValue));

    }



    public function testBinaryResourceConvertsToPHPValue(): void