예제 #1
0
        protected virtual GraphMemberCategoryNodeViewModel CreateCategory(GraphNodeViewModel graph, GraphMemberType graphMemberType, bool isExpanded)
        {
            switch (graphMemberType)
            {
            case GraphMemberType.View:
                return(new ViewCategoryNodeViewModel(graph, isExpanded));

            case GraphMemberType.Action:
                return(new ActionCategoryNodeViewModel(graph, isExpanded));

            case GraphMemberType.CacheAttached:
                return(new CacheAttachedCategoryNodeViewModel(graph, isExpanded));

            case GraphMemberType.RowEvent:
                return(new RowEventCategoryNodeViewModel(graph, isExpanded));

            case GraphMemberType.FieldEvent:
                return(new FieldEventCategoryNodeViewModel(graph, isExpanded));

            case GraphMemberType.PXOverride:
                return(new PXOverridesCategoryNodeViewModel(graph, isExpanded));

            case GraphMemberType.NestedDAC:
            case GraphMemberType.NestedGraph:
            default:
                return(null);
            }
        }
        public override IEnumerable <TreeNodeViewModel> VisitNode(GraphNodeViewModel graph)
        {
            foreach (GraphMemberType graphMemberType in GetGraphMemberTypesInOrder())
            {
                Cancellation.ThrowIfCancellationRequested();
                GraphMemberCategoryNodeViewModel graphMemberCategory = CreateCategory(graph, graphMemberType);

                if (graphMemberCategory != null)
                {
                    yield return(graphMemberCategory);
                }
            }
        }
예제 #3
0
        public override IEnumerable <TreeNodeViewModel> VisitNodeAndBuildChildren(GraphNodeViewModel graph, bool expandChildren, CancellationToken cancellation)
        {
            foreach (GraphMemberType graphMemberType in GetGraphMemberTypesInOrder())
            {
                cancellation.ThrowIfCancellationRequested();
                GraphMemberCategoryNodeViewModel graphMemberCategory = CreateCategory(graph, graphMemberType, expandChildren);

                if (graphMemberCategory != null)
                {
                    yield return(graphMemberCategory);
                }
            }
        }
 public GraphInitializationAndActivationCategoryNodeViewModel(GraphNodeViewModel graphViewModel, bool isExpanded) :
     base(graphViewModel, GraphMemberType.InitializationAndActivation, isExpanded)
 {
 }
 public virtual TResult VisitNode(GraphNodeViewModel graph) => DefaultVisit(graph);
 protected virtual GraphMemberCategoryNodeViewModel CreateCategory(GraphNodeViewModel graph, GraphMemberType graphMemberType) =>
 graphMemberType switch
 {
 public virtual TResult VisitNode(GraphNodeViewModel graph, TInput input) => DefaultVisit(graph, input);
 public ActionCategoryNodeViewModel(GraphNodeViewModel graphViewModel, bool isExpanded) :
     base(graphViewModel, GraphMemberType.Action, isExpanded)
 {
 }
예제 #9
0
 public ViewCategoryNodeViewModel(GraphNodeViewModel graphViewModel, bool isExpanded) :
     base(graphViewModel, GraphMemberType.View, isExpanded)
 {
 }
 public FieldEventCategoryNodeViewModel(GraphNodeViewModel graphViewModel, bool isExpanded) :
     base(graphViewModel, GraphMemberType.FieldEvent, isExpanded)
 {
 }
 public CacheAttachedCategoryNodeViewModel(GraphNodeViewModel graphViewModel, bool isExpanded) :
     base(graphViewModel, GraphMemberType.CacheAttached, isExpanded)
 {
 }
 public virtual IEnumerable <TreeNodeViewModel> VisitNodeAndBuildChildren(GraphNodeViewModel graph, bool expandChildren,
                                                                          CancellationToken cancellation) =>
 Enumerable.Empty <TreeNodeViewModel>();
예제 #13
0
 public PXOverridesCategoryNodeViewModel(GraphNodeViewModel graphViewModel, bool isExpanded) :
     base(graphViewModel, GraphMemberType.PXOverride, isExpanded)
 {
 }