Example #1
0
        private void LoadListView()
        {
            // add all of the classes into the listview. we will also want to load the elements as we go.

            ListView lv = this.oInfoView;

            List <ListViewOntologyInfoEntry> lvoes = new List <ListViewOntologyInfoEntry>();

            foreach (String oClassName in this.oInfo.GetClassNames())
            {
                OntologyClass             oClass = this.oInfo.GetClass(oClassName);
                ListViewOntologyInfoEntry curr   = new ListViewOntologyInfoEntry(oClass.GetNameString(true), oClass.GetNameString(false), oClass.GetNamepaceString(), oClass);
                lvoes.Add(curr);
            }

            lv.ItemsSource = lvoes;
        }
Example #2
0
        private void Button_Click_1(object sender, RoutedEventArgs e)
        {
            if (this.oInfoView.SelectedIndex == -1)
            {   // pop a diagloue that nothing was selected.
                Debug.WriteLine("no node selected. nothing to do.");

                return;
            }

            else
            {
                OntologyClass oClass = ((ListViewOntologyInfoEntry)this.oInfoView.SelectedItem).OClass;

                Node newlyCreatedNode = this.queryNodeGroup.ReturnBelmontSemanticNode(oClass.GetNameString(false), this.oInfo);

                Debug.WriteLine("created new node for nodegroup. it is currently not added to the nodeGroup.");
                Debug.WriteLine("node uri is: " + newlyCreatedNode.GetFullUriName());

                this.HandleNodeGroupNodeAdditions(newlyCreatedNode);
            }
        }