Implemented the reading of structs