Simple Java socket implementation with byte support