Looking for design help
Posted
by jess
on Stack Overflow
See other posts from Stack Overflow
or by jess
Published on 2010-04-16T12:31:07Z
Indexed on
2010/04/16
12:33 UTC
Read the original article
Hit count: 269
design-patterns
I have this scenario in most of the WindowsForms having grids I have a sequence of code which is similar - AddNewRow(in grid),CreateNewEntity,notifyUser,few other steps Now, I want to use a template kind of pattern.But,my issue is with CreateEntity method since sometimes it is passed a parameter which is different depending on the type of object being created.Should I make createentity accept an "object" type,and cast when the parameter is to be used.What other way can I tackle this design issue? Also,CreateEntity returns the object being created.
© Stack Overflow or respective owner