On Saturday, 29 December 2018 17:31:57 UTC+1, Woody Gilk wrote: > > From my perspective, it would make sense that the position would be always > be set to the end of the stream, as if the stream had just been written, > mirroring the fopen(), fwrite() sequence that would normally be done. > > I'm not quite sure on the bylaws about level of recommendation, but an > errata to the following would cover this: > > Streams SHOULD have their internal pointer set to the end of the > underlying resource. >
Do you imagine this for all Stream instances or just those created with createStream()? I can see a problem with trying to move the cursor within others as the underlying file/resource may not be seekable (thus something like fseek($handle, 0, SEEK_END) wouldn’t work) or because for a true streaming resource the end of the data stream may not be known yet (e.g. live streaming). This is why my initial thought was that all three methods may require separate cursor behaviour. -- You received this message because you are subscribed to the Google Groups "PHP Framework Interoperability Group" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/php-fig/6cb35e13-9d27-408d-b7a1-074b3fc0ebca%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
