Updated to change structs to classes