|
From: Elmer G. <ega...@us...> - 2004-07-28 06:54:25
|
Update of /cvsroot/javaowl/JavaOWL/src/org/javaowl/editor In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv18474/src/org/javaowl/editor Modified Files: ModelEditorBean.java ResourceEditorBean.java Log Message: Changed serialization to externalization. Index: ModelEditorBean.java =================================================================== RCS file: /cvsroot/javaowl/JavaOWL/src/org/javaowl/editor/ModelEditorBean.java,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** ModelEditorBean.java 27 Jul 2004 17:25:35 -0000 1.7 --- ModelEditorBean.java 28 Jul 2004 06:54:06 -0000 1.8 *************** *** 136,140 **** return result; } ! public OntProperty[] getAllProperties() { Set props = new HashSet(); --- 136,140 ---- return result; } ! //TODO: rename getAllDatatypeProperties public OntProperty[] getAllProperties() { Set props = new HashSet(); *************** *** 170,174 **** } ! public OntClass createClass(Resource resource) { return ontModel.createClass(resource.getURI()); --- 170,174 ---- } ! //TODO: rename getOntClass etc ... public OntClass createClass(Resource resource) { return ontModel.createClass(resource.getURI()); *************** *** 188,191 **** --- 188,192 ---- } + //TODO: remove where resource is object public void removeResource(Resource resource) { List stmts = new ArrayList(); *************** *** 206,218 **** return (OntClass[]) classes.toArray(new OntClass[0]); } ! ! public Resource[] getDataResources() { ! // TODO: What is this for? ! List resources = new ArrayList(); ! for (Iterator it = data.listSubjects(); it.hasNext();) ! resources.add(it.next()); ! return (Resource[]) resources.toArray(new Resource[0]); ! } ! public ResourceEditorBean getNewResourceEditor(OntResource classResource) { Resource r = data.createResource(); --- 207,211 ---- return (OntClass[]) classes.toArray(new OntClass[0]); } ! //TODO: look for better names public ResourceEditorBean getNewResourceEditor(OntResource classResource) { Resource r = data.createResource(); *************** *** 248,252 **** throw new RuntimeException("ontology reasoner exception: ", e); } ! List classes = new ArrayList(); List leafClasses = new ArrayList(); --- 241,245 ---- throw new RuntimeException("ontology reasoner exception: ", e); } ! //TODO: Remove leafClasses methods List classes = new ArrayList(); List leafClasses = new ArrayList(); Index: ResourceEditorBean.java =================================================================== RCS file: /cvsroot/javaowl/JavaOWL/src/org/javaowl/editor/ResourceEditorBean.java,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** ResourceEditorBean.java 23 Jul 2004 01:18:50 -0000 1.4 --- ResourceEditorBean.java 28 Jul 2004 06:54:06 -0000 1.5 *************** *** 48,53 **** private final Resource resource; - // private OntClass[] types; - private final String prefix; --- 48,51 ---- *************** *** 94,104 **** return result; } ! ! /* ! public OntClass[] getTypes() { ! return types; ! } ! */ ! public Statement[] getProperties() { List resources = new ArrayList(); --- 92,96 ---- return result; } ! //TODO: rename getDeclaredPRoperties public Statement[] getProperties() { List resources = new ArrayList(); *************** *** 114,126 **** return false; } ! ! public OntResource[] getValidClasses(OntProperty property) { ! // TODO: This method is never called! ! List resources = new ArrayList(); ! for (Iterator it = property.listRange(); it.hasNext();) ! resources.add(it.next()); ! return (OntResource[]) resources.toArray(new OntResource[0]); ! } ! public OntResource getValidLeafClass(Property property) { OntProperty op; --- 106,111 ---- return false; } ! //TODO: get all valid Instances for the range intersection and the ! // resource restrictions public OntResource getValidLeafClass(Property property) { OntProperty op; |