Update of /cvsroot/hibernate/Hibernate/cirrus/hibernate/tools/codegen
In directory sc8-pr-cvs1:/tmp/cvs-serv28440/cirrus/hibernate/tools/codegen
Modified Files:
ClassMapping.java
Log Message:
CodeGenerator now recognizes <version> and <timestamp> (patch by Max Andersen)
Index: ClassMapping.java
===================================================================
RCS file: /cvsroot/hibernate/Hibernate/cirrus/hibernate/tools/codegen/ClassMapping.java,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -d -r1.16 -r1.17
*** ClassMapping.java 28 Nov 2002 09:54:33 -0000 1.16
--- ClassMapping.java 28 Nov 2002 12:33:34 -0000 1.17
***************
*** 50,56 ****
// get the properties defined for this class
List propertyList = new ArrayList();
-
propertyList.addAll( classElement.getChildren("property") );
!
Attribute att = classElement.getAttribute("proxy");
if (att!=null) proxyClass = att.getValue();
--- 50,57 ----
// get the properties defined for this class
List propertyList = new ArrayList();
propertyList.addAll( classElement.getChildren("property") );
! propertyList.addAll( classElement.getChildren("version") );
! propertyList.addAll( classElement.getChildren("timestamp") );
!
Attribute att = classElement.getAttribute("proxy");
if (att!=null) proxyClass = att.getValue();
***************
*** 67,73 ****
String cmpclass = cmpid.getAttributeValue("class");
if ( cmpclass==null || cmpclass.equals("") ) {
! propertyList.addAll(cmpid.getChildren("key-property"));
! for (Iterator it = cmpid.getChildren("key-many-to-one").iterator();
! it.hasNext(); ) {
Element manyToOne = (Element) it.next();
--- 68,73 ----
String cmpclass = cmpid.getAttributeValue("class");
if ( cmpclass==null || cmpclass.equals("") ) {
! propertyList.addAll( cmpid.getChildren("key-property") );
! for ( Iterator it = cmpid.getChildren("key-many-to-one").iterator(); it.hasNext(); ) {
Element manyToOne = (Element) it.next();
|