Made the model classes which takes arrays in setters type safe.

Will now type-check array items and warn when wrong types are sent in.
Array types are also documented correctly.