Strongly typed API for ASP.NET MVC 2 async actions -


Has anyone tried to create a strong type API for ASP .NET MVC 2 async functions?

Best regards, Alexey Wakharov

I believe that we Have done something like this recently if I have understood you correctly, we use JsonValueProviderFactory to get a strong type action (more on this) from ASP.Net MVC 2 Future Library.

We have something similar to this async action:

[HandleError] Public class HomeController: AsyncController {[HttpPost] Public Zero Index Sense (person) {DoSomething ( ); } Includes Public Performance Index () {Return View (); }} Public class person {public string forename {get; Set; } Public string aliases {get; Set; }}

And to post an action, just post it:

  {"Forename": "cheishi", "surname": "goat "}  

This Firefox plug-in is also to help in testing 'rest clients' which I will also recommend.

Hope it helps.


Comments