This project is read-only.

Code Generation

In general Commerce Server APIs are weakly typed to provide the ultimate in extensibility and flexibility. This makes defining your custom data relatively easy, but at the expense of having to deal with many strings within code. To take advantage of Visual Studio intellisense we created the Commerce Server Contrib Code Generation project. The output of the project is a dll that gathers as much metadata as possible about Commerce Server and allows you to transform this data into something simple using T4 templates.

The site templates leverage the Code Generation project (referenced via NuGet) to generate strongly typed CommerceEntities and Request Template calls. Any time you update the request template file or modify any part of your Commerce Server subsystem schemas, you should rebuild the T4 templates so that the generated code accurately reflects the state of your project.

The T4 templates in the project are offered as guidance, so feel free to change them to suit your needs, and if you have any suggestions or bug fixes, please feel free to fork the project and send us a pull request.

Last edited Nov 23, 2012 at 4:45 PM by beaulieuj, version 2


No comments yet.