reading from a ubyte[] | byte[] as if from a stream? (Phobos)

BCS ao at pathlink.com
Thu Sep 18 13:19:32 PDT 2008


Reply to Charles,

> Is it possible to read from a byte or ubyte array as if from a stream?
> It looks like it should be not only possible, but easy...but I haven't
> figured it out.
> 
> BufferedFile *MUST* do that kind of thing internally, but it feels
> like there ought to be a way to say "This array is your data, read
> from it!" rather than digging through the guts of it and copying all
> the relevant code into a separate code-space.
> 

MemoryStream
http://www.digitalmars.com/d/1.0/phobos/std_stream.html




More information about the Digitalmars-d-learn mailing list