Beispiel #1
0
 public frmConsult(ESys exsys, string g)
 {
     InitializeComponent();
     es = exsys;
     goals.Push(g);
     es.ConflictSet.Clear();
     es.WorkMemory.Clear();
     maingoal    = g;
     currentnode = new TreeNode("Цель консультации: " + g);
 }
Beispiel #2
0
 public static void prepare_edit(ESys es, string editname)
 {
     ESys.LSideRow[] rows = es.LSide.Where(e => e.Имя == editname).ToArray();
     foreach (ESys.LSideRow row in rows)
     {
         es.LSide.RemoveLSideRow(row);
     }
     ESys.RSideRow[] rowss = es.RSide.Where(e => e.Имя == editname).ToArray();
     foreach (ESys.RSideRow row in rowss)
     {
         es.RSide.RemoveRSideRow(row);
     }
 }
Beispiel #3
0
 public frmExplain(TreeNode tv, frmMain par)
 {
     InitializeComponent();
     treeRules.Nodes.Clear();
     treeRules.Nodes.Add(tv);
     es = par.es;
     DataRow[] rows =
         (from works in es.WorkMemory
          join facts in es.Fact
          on works.fact equals facts.id
          select facts).ToArray();
     foreach (ESys.FactRow fact in rows)
     {
         dataVarVal.Rows.Add(fact.Переменная, fact.Значение_переменной);
     }
 }