What is the best way to copy the contents of one stream to another? Is there a standard utility method for this?
The basic questions that differentiate implementations of "CopyStream" are:
The answers to these questions result in vastly different implementations of CopyStream and are dependent on what kind of streams you have and what you are trying to optimize. The "best" implementation would even need to know what specific hardware the streams were reading and writing to.