Пример #1
0
        public void AddStat(IStat stat, NodeType nodeType = NodeType.Total)
        {
            var resultStat = new ResultStatViewModel(_nodeFactory.CreateResult(stat, nodeType), RemoveStat);

            Stats.Add(resultStat);
            AddAvailableStat(stat);
        }
Пример #2
0
        protected override ResultNodeViewModel CreateViewModel(ICalculationNode?node, IStat stat)
        {
            var nodeType = ((ExplicitRegistrationType.IndependentResult)stat.ExplicitRegistrationType !).ResultType;

            return(_nodeFactory.CreateResult(stat, nodeType));
        }