improve class ByteBuffer
remove header dependencies for two buffer classes