modified element array to element list. finished encoding int32, int64 and float. need to continue to finish the encoding of doc