by jonathan.carter on Mon Nov 09, 2009 12:55 pm
Hi Sean,
I've just had a go at replicating what you describe. The "instances" field is actually a field to specify the output XML file for the selected Class, although I found that dragging a class over there put the name of the class in that field. However, my class stayed put in the class browser.
The class browser allows you to refactor the class hierarchy by dragging the classes around - although I would advise caution with this. It's possible that you've accidentally dragged the class into another location in the hierarchy. If you do do this, it's worth doing a quick "undo" to put things back. It may be too late for that now, in which case, search for your class by name in any of the Class browsers, e.g. on the Instances tab or in the XMLTab and you should be able to find it. I'm sure Protege will not allow you to remove a class that has instances, so it's very unlikely that the class has been deleted unless there's a bug with the XMLTab.
When you find your class, you can put it back in the correct place in the hierarchy.
I haven't really had much use of the XMLTab - I couldn't get it to do what I needed in earlier versions (3.1 / 3.3.1) of Protege. If you are trying to create an XML export of the contents of your Essential Repository (the instances), this is exactly what the Essential Architecture Reporting tab does and sends it to the Essential Viewer reporting environment - and I would strongly advise using that in preference to the XMLTab, even if you only want a sub-set of the repository.
You can pick up the exported XML file from the 'essential_viewer' root directory in your Tomcat environment (filename: reportXML.xml) and process the XML as required. Or - what we normally do - create an XSL extract report that pulls out the required instances from the complete repository snapshot, e.g. to get into Excel or whatever.
Note, that the Essential Architecture Reporting tab ONLY takes the instances not the classes. However, the format used is the same as that of the 'Experimental XML file' project format of Protege. This XML format DOES include both Classes and Instances in the XML file. If you need the classes as well, convert your project to the XML format and then explore the resulting XML file.
Hope all this helps - let me know how you get on
Jonathan
Essential Project Team