Lines Matching refs:stream
2 Pdo\Sqlite::blobOpen stream test
26 $stream = $db->openBlob('test', 'data', 1);
27 var_dump($stream);
29 var_dump(stream_get_contents($stream));
30 echo "Writing to read-only stream\n";
31 var_dump(fwrite($stream, 'ABCD'));
33 var_dump(fclose($stream));
34 echo "Opening stream in write mode\n";
35 $stream = $db->openBlob('test', 'data', 1, 'main', Pdo\Sqlite::OPEN_READWRITE);
36 var_dump($stream);
38 var_dump(fwrite($stream, 'ABCD'));
40 fseek($stream, 0);
41 var_dump(stream_get_contents($stream));
43 var_dump(fwrite($stream, 'ABCD ABCD ABCD'));
45 var_dump(fclose($stream));
56 resource(%d) of type (stream)
59 Writing to read-only stream
61 Warning: fwrite(): Can't write to blob stream: is open as read only in %s on line %d
65 Opening stream in write mode
66 resource(%d) of type (stream)