New parseToArray method

I added the parseToArray method and changed the surface getter to return an empty string instead of looking in the memory from the dangling pointer (security issue).