Exemplo n.º 1
0
        protected override void ProtectedCloneTo(INodeComponentCollection componentCollection)
        {
            if (componentCollection is not INodeComponentAutoCloner cloner)
            {
                throw new ArgumentException("NodeComponentAutoCloner can only copy to other NodeComponentAutoCloners");
            }

            cloner.ResetWith(_originalClone, _minimumFieldCount, _nameRule);
        }
Exemplo n.º 2
0
        public NodeBase(INode baseNode)
        {
            _baseNode                = baseNode;
            _fieldSection            = Constructor.NodeComponentList(baseNode.Fields);
            _fieldSection.ParentNode = baseNode;

            Fields = ObservableCollectionMapper <IVisualNodeComponent, IVisualNodeComponentDisplay> .Create(_fieldSection.VisualNodeComponentsObservable, new VisualNodeComponentMapper(this));

            baseNode.SubscribeToEvaluate(TryEvaluate);

            TryEvaluate();
        }