コード例 #1
0
 public bool AddLogicRuleAfterSentinel(ILogicRule lr, string sentmarker)
 {
     for (int i = 0; i < this.l.Count; i++)
     {
         LogicRuleSentinel sentinel = this.l[i] as LogicRuleSentinel;
         if ((sentinel != null) && (sentinel.Marker == sentmarker))
         {
             this.l.Insert(i + 1, lr);
             return(true);
         }
     }
     return(false);
 }
コード例 #2
0
        public ReadOnlyCollection <string> GetLogicSentinelLabels()
        {
            List <string> list = new List <string>();

            foreach (ILogicRule rule in this.l)
            {
                LogicRuleSentinel sentinel = rule as LogicRuleSentinel;
                if (sentinel != null)
                {
                    list.Add(sentinel.Marker);
                }
            }
            return(list.AsReadOnly());
        }