Exemplo n.º 1
0
        /// <summary>
        /// Register "And", "Or", "Not" conditionDefs in ctor.
        /// Because, all rule engine based systems will use these three kinds of conditions.
        /// They are basic logic nodes.
        /// </summary>
        protected AbstractConditionManager()
        {
            AndConditionDef andConditionDef = AndConditionDef.GetInstance();

            RegisterCondition(andConditionDef.GetConditionName(), andConditionDef);
            OrConditionDef orConditionDef = OrConditionDef.GetInstance();

            RegisterCondition(orConditionDef.GetConditionName(), orConditionDef);
            NotConditionDef notConditionDef = NotConditionDef.GetInstance();

            RegisterCondition(notConditionDef.GetConditionName(), notConditionDef);
        }
Exemplo n.º 2
0
 public override IConditionDef GetConditionDef()
 {
     return(OrConditionDef.GetInstance());
 }