Added reading and writing modes to net buffers. Rewinds when mode switches.