I am trying to figure out how to pass a class/struct/etc.. using named pipe between thread(I am trying to measure some performance using the stopwatch and compare it to other methods..)
Anyway , All the documention I’ve found is talking about using StreamReader and readline to get the data from the NamedPipeServerStream. However readline is a string, how do I actually use the data from the named pipe if I am passing something that is not a string.
Thanks,
Eyal
NamedPipeServerStreamis a stream – so it’s fine for binary data out of the box. Just treat it like a normal stream, rather than wrapping it in aStreamReader.As for passing objects – why used named pipes if you’re strictly within a single process? Just create an in-memory producer/consumer queue.