|Post date: 2007-05-15 10:51|
I'm writing WebServices and one thing would be really nice to do is to generate the public variables for one of the classes dynamically.
The "same" WS is used in a lot of databases, the only difference is the data it returns. What I mean to say is: It's the same functions that are used: hasErrands, getList, getDetails.
The different databases have different data of course, but the only thing that changes is the way the views are setup to display the contents. I could easily enough construct the views so that I could retrive the fieldnames to be used in the Class. But I can't construct the public variables in the class based on this information, they have to be hardcoded. Or do they?
I was thinking maybe something with "Execute"?
The benefit would be that any, less skilled, developer could easily update the WS just by updating the corresponding view. Also meaning that you could have one central repository for storing the WS and then have the different databases inherit the design from there.