Remove OpenStruct dependency and add generating custom methods