How to create nettiers templates from compiled code that was generated in nettiers

152 views Asked by At

I have recently inherited a web site application that incorporates layers generated in nettiers. I need to continue to use these layers, but as I develop and update my database design, I need to regenerate these layers.

I do not have the templates or configuration settings for nettiers that were used by the previous developers to generate these layers (data, entity, web service, sql).

How can I reverse the process, to generate the configuration from looking at the resulting layers/VS projects? Is this possible? Or am I stuck in a game of trial and error until I can reproduce these dlls to match what I have currently?

This will be a large waste of time, if the original template or configuration was available or able to be recreated.

Oh... and I am brand new to nettiers, so, sorry if this is an obvious or dumb question.

Thanks!!!

1

There are 1 answers

0
Jereme On

This is a very old question. But for those reading it in the future, here is the answer.

There is no direct way to reverse the process to get the template settings used for generation if they get lost. It would not be a bad idea to keep a copy of them in source control.

That said, many of the options should be fairly obvious, which hopefully will make the brute force process of figuring out the right settings take much less time.

Generating the code and then trying to compile the project should give you a pretty good idea of which features you are using that you did not choose in the templates.

My recommendation would be to pick one table and do a comparison of the old generated file against the newly generated file, the differences should also tell you if you have settings incorrect.

This does fall apart if developers for your project have been allowed to perform multiple generations using different name spaces. If you are in that scenario, and don't have the time to fix the code. Then you are in for a painstakingly manual process of generating the code and only copying in the changes you need to your project.