Interfaces

Project

Pages Html

NuGet packageOwin.Framework.Pages.Html
GitHub sourceOwinFramework.Pages.Html

Home |  Readme

[SuppliesData] attribute | The OWIN Framework Pages

The [SuppliesData] Attribute

The [SuppliesData] attribute can be attached to data providers that provide multiple kinds of data, or the same data in multiple data scopes.

The [SuppliesData()] attribute has the following properties you can set.

DataType

Defines ab additional type of data that this data provider can provide. This must be either a C# class type, or an IList<T> type.

Scope

Specifies a scope name. When this is set, this data provider will only be considered as the supplier of data when the page element specifies that it needs data in this specific scope.

When the scope name is not set, this means that this data provider can provide this kind of data for all scopes. In this case this data provider will only be used if there are no scope specific data providers that match the request.

In the case where there are multiple data providers that can provide the data, the one that will be selected depends on what other data is required on the page, and the other types of data that each provider can provide.