From: Xuan B. <med...@us...> - 2008-01-22 21:49:06
|
Update of /cvsroot/tm4j/tm4j/src/org/tm4j/topicmap/tmdm/tm4j1 In directory sc8-pr-cvs10.sourceforge.net:/tmp/cvs-serv3471/src/org/tm4j/topicmap/tmdm/tm4j1 Modified Files: TopicImpl.java Log Message: Implement TopicImpl.createName(String id) legacy method. Index: TopicImpl.java =================================================================== RCS file: /cvsroot/tm4j/tm4j/src/org/tm4j/topicmap/tmdm/tm4j1/TopicImpl.java,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** TopicImpl.java 22 Jan 2008 20:58:11 -0000 1.5 --- TopicImpl.java 22 Jan 2008 21:49:10 -0000 1.6 *************** *** 316,322 **** * violate a constraint imposed by a VetoableChangeListener assigned to * this TopicMap. */ public BaseName createName(String id) throws DuplicateObjectIDException, PropertyVetoException { ! throw new UnsupportedOperationException(); } --- 316,324 ---- * violate a constraint imposed by a VetoableChangeListener assigned to * this TopicMap. + * @deprecated As of TMDM, it is not allowed to have names without value. */ + @Deprecated public BaseName createName(String id) throws DuplicateObjectIDException, PropertyVetoException { ! return createName(id,""); } *************** *** 335,338 **** --- 337,342 ---- */ public BaseName createName(String id, String nameString) throws DuplicateObjectIDException, PropertyVetoException { + assert id==null; // currently not implemented + return getContainer().unmergedToExternal(getRepresentedObject().createTopicName(nameString,null)); } |