Hello,
I don't quite understand the question / necessity to handle download / uploads manually. There are already good upload / download handlers / web scripts in Alfresco out of the box.
In regards to the core of your question: No matter how you work with files, all methods deal with arrays of bytes, because that is what files ultimately are - streams of bytes. You can use the standard Input-/OutputStream abstractions via the ContentReader/ContentWriter interfaces of Alfresco to stream the bytes without you having to handle arrays of bytes yourself. Of course this requires you have a streamable input / output in the request you are processing. When using HTTP (via Servlet or Web Script) you have the Input-/OutputStream of the HTTP request.
Regards
Axel