Ejemplo n.º 1
0
        public ModelCheckingForm(string Name, SpecificationBase spec)
        {
            ModelCheckingFormInstance = this;
            InitializeComponent();

            InitializeResourceText();

            this.Spec = spec;

            int Index = 1;

            foreach (KeyValuePair <string, AssertionBase> entry in Spec.AssertionDatabase)
            {
                ListViewItem item = new ListViewItem(new string[] { "", Index.ToString(), entry.Key });

                //if the assertion is LTL, the button of the view BA should be enabled.
                if (entry.Value is AssertionLTL)
                {
                    item.Tag = "LTL";

                    //BuchiAutomata BA = (entry.Value as AssertionLTL).BA;

                    //if (BA != null)
                    //{
                    //    if (BA.HasXOperator)
                    //    {
                    //        item.SubItems[0].Tag = true;
                    //    }
                    //}
                }


                //set the question mark image
                item.ImageIndex = 2;

                this.ListView_Assertions.Items.Add(item);
                Index++;
            }

            if (Name != "")
            {
#if DEBUG
                this.Text = this.Text + " (Debug Model) - " + Name;
#else
                this.Text = this.Text + " - " + Name;
#endif
            }

            this.StatusLabel_Text.Text = Resources.Select_an_assertion_to_start_with;
        }
Ejemplo n.º 2
0
        protected void initLogic()
        {
            ModelCheckingFormInstance = this;
            InitializeResourceText();

            int Index = 1;
            ListView_Assertions.Items.Clear();
            foreach (KeyValuePair<string, AssertionBase> entry in mSpecWorker.mSpec.AssertionDatabase)
            {
                ListViewItem item = new ListViewItem(new string[] { "", Index.ToString(), entry.Key });

                // If the assertion is LTL, the button of the view BA should be enabled.
                if (entry.Value is AssertionLTL)
                    item.Tag = "LTL";                             

                // Set the question mark image
                item.ImageIndex = 2;

                this.ListView_Assertions.Items.Add(item);
                Index++;
            }

            this.StatusLabel_Text.Text = Resources.Select_an_assertion_to_start_with;
        }
Ejemplo n.º 3
0
 private void ModelCheckingForm_FormClosed(object sender, FormClosedEventArgs e)
 {
     ModelCheckingFormInstance = null;
     GC.Collect();
 }
Ejemplo n.º 4
0
 private void ModelCheckingForm_FormClosed(object sender, FormClosedEventArgs e)
 {
     ModelCheckingFormInstance = null;
     GC.Collect();
 }
Ejemplo n.º 5
0
        protected void initLogic()
        {
            ModelCheckingFormInstance = this;
            InitializeResourceText();

            int Index = 1;
            ListView_Assertions.Items.Clear();
            foreach (KeyValuePair<string, AssertionBase> entry in mSpecWorker.mSpec.AssertionDatabase)
            {
                ListViewItem item = new ListViewItem(new string[] { "", Index.ToString(), entry.Key });

                // If the assertion is LTL, the button of the view BA should be enabled.
                if (entry.Value is AssertionLTL)
                    item.Tag = "LTL";

                // Set the question mark image
                item.ImageIndex = 2;

                this.ListView_Assertions.Items.Add(item);
                Index++;
            }

            this.StatusLabel_Text.Text = Resources.Select_an_assertion_to_start_with;
        }