New to Telerik UI for ASP.NET Core? Download free 30-day trial

HierarchicalModelDescriptorBuilder

Methods

Id(System.String)

Specify the member used to identify an unique Model instance.

Parameters

fieldName - System.String

The member name.

Example


                 .DataSource(dataSource => dataSource
                       .Model(model => model
                            .Id("ID")
                       )
                 )

Children(System.String)

Specify the model children member name.

Parameters

fieldName - System.String

The member name.

Example


                .DataSource(dataSource => dataSource
                      .Model(model => model
                           .Children("children")
                      )
                )

Children(System.Action)

Specify the children DataSource configuration.

Parameters

configurator - System.Action<HierarchicalDataSourceBuilder>

The configurator action.

Example


                .DataSource(dataSource => dataSource
                      .Model(model => model
                           .Children(children => children
                                .Read("Read", "TreeViewChildren")
                           )
                      )
                )

HasChildren(System.String)

Specify the member name used to determine if the model has children.

Parameters

fieldName - System.String

The member name.

Example


                .DataSource(dataSource => dataSource
                      .Model(model => model
                           .HasChildren("hasChildren")
                      )
                )

Field(System.String,System.Type)

Describes a Model field

Parameters

memberName - System.String

Field name

memberType - System.Type

Field type

Example


                .DataSource(dataSource => dataSource
                        .Model(model => model
                            .Field("Name", typeof(string))
                        )
                )

In this article
Not finding the help you need?