I get a array via SOAP service, in the array in each value which is a struct is a description of any visual components (size, position, default value etc.) like CheckBox, RadioButton etc. And I wonder about how to write a code which will return instances of those any visual components according to the input parameter with usage a design pattern. Which design pattern is the best for this purpose? 
Creating classes according to a struct
design patterns