implement byte string encode
implement UTF string encode