Skip to content
This repository was archived by the owner on Nov 9, 2018. It is now read-only.

Main AcspNet principles

Alexanderius edited this page Sep 19, 2014 · 5 revisions

AcspNet uses MVC pattern, so it has controllers which processes HTTP request, views which generates page contents (not needed for very small pages, because StaticTpl controller response or Tpl controller response can be used etc.) and model - your entity classes.

It also uses similarity of MVVM pattern, so controllers can get view model from request via using Controller<T> And AsyncController<T> classes and Model property. And can send view model by ITemplate.Model extension method to template.

AcspNet pipeline

  1. AcspNet receives incoming HTTP request;
  2. Creates controllers instances via IOC container which can handle current request;
  3. Executes controllers instances;
  4. Processes controllers responses;
  5. Builds page: loads Master.tpl template, inserts data from DataCollector class to it, sets AcspNet variables;
  6. Sends generated page to client.

If controller returns Redirect response of Ajax response etc. then the 5, 6 step will be skipped.

If current request is a request for static file and it is available for process, then the 2 step and above will be skipped.

<< Previous page Next page >>

Clone this wiki locally