ModelEditorGroupingHelper.RegisterNodeGroupPathDelegate(Type, Func<IModelNode, String[]>) Method

Registers the method used to calculate the Application Model node's group path in the Model Editor's Nodes Tree.

Namespace: DevExpress.ExpressApp.ModelEditor

Assembly: DevExpress.ExpressApp.v18.1.dll


public void RegisterNodeGroupPathDelegate(
    Type collectionNodeType,
    Func<IModelNode, string[]> GetNodeGroupPathDelegate


Type Name Description
Type collectionNodeType

A Type object specifying the type of the Application Model node.

System.Func<IModelNode, String[]> GetNodeGroupPathDelegate

A delegate used to calculate the Application Model node's group path.

You can call the RegisterNodeGroupPathDelegate method in the platform-agnostic module's constructor.

using DevExpress.ExpressApp.ModelEditor;
// ...
public sealed partial class MySolutionModule : ModuleBase {
    public MySolutionModule () {
        ModelEditorGroupingHelper.Instance.AllowSplitByGroupLevels = true;
            typeof(IModelViews), node => CusomGroupPathCalculator(node));
    public string[] CusomGroupPathCalculator(IModelNode node) {
        // ...
    // ...

You can use the ModelEditorGroupingHelper.SplitGroupPath helper method in your custom delegate to calculate the group path.

The ModelEditorGroupingHelper provides two built-in delegates that can be passed to the RegisterNodeGroupPathDelegate method: