Not all streams are implemented at this level, most of the built-in modules are at C level, so no, because PHP is not a streamwrapper
object. This interface ensures that it works as a stream, and not vice versa. (Essentially: all streaming parties can be accessed as a stream resource, but not all stream resources are provided by streamwrapper classes). However, you can override, for example, the file:///
packaging and other built-in functions, great fun.
source share