ModelCacheManager Class
Manages the Application Model cache designed to improve the startup speed and performance.
Namespace: DevExpress.ExpressApp
Assembly: DevExpress.ExpressApp.v24.2.dll
NuGet Package: DevExpress.ExpressApp
#Declaration
#Related API Members
The following members return ModelCacheManager objects:
#Remarks
You can customize the ModelCacheManager behavior using the following static fields.
Field | Description |
---|---|
Model |
Enables multi-thread loading of the Application Model cache. |
Model |
Enables skipping empty nodes when creating and loading the Application Model cache. |
Setting both these fields to true may reduce the application startup time when the Application Model cache is enabled (see XafApplication.EnableModelCache). As these fields are static, you can access them from any code location that is executed before the Application Model cache is accessed:
- in the constructor of your platform-agnostic module located in the Module.cs (Module.vb) file;
- in the constructor of your application located in the WinApplication.cs (WinApplication.vb) or WebApplication.cs (WebApplication.vb) file;
- in the Main method of the WinForms application located in the Program.cs (Program.vb) file, before the WinApplication.Start call;
- in the Application_Start method of the ASP.NET Web Forms application located in the Global.asax.cs (Global.asax.vb) file, before the WebApplication.Start call.
Important
If Skip
For deeper customizations, inherit this class, handle the XafApplication.CreateCustomModelCacheManager event and pass your custom ModelCacheManager descendant to the CreateCustomModelCacheManagerEventArgs.ModelCacheManager parameter. An example is provided in the XafApplication.CreateCustomModelCacheManager event description.