I have a system with few model classes, each one with another members, but the behavior of all models are same-
For example, all models are request input from user in this format:
Hi, Please enter {MemberName} value as {MemberType}:
And convert the input to MemberType.
Because this intended to be library, I want that in each model I can to access his members (or members-like) at compile time, not by myModel.get("memberName"), but rather by myModel.memberName or myModel.get(modelEnum.MemberName) or myModel.ListOfMember[0] or maybe Factory.getMember(myModel, SpecificModelMembersList[0]) etc..
I don't need to add or remove members in runtime, just create a good way to add them in compile time, and not change all the code for add member to model class.
How would you design it?
I work with C#.
Thank you and you can suggest an english fixes.