-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: xdoclet composite-id
PostPosted: Sun Jul 11, 2004 7:57 am 
Newbie

Joined: Mon May 10, 2004 7:58 am
Posts: 15
hi,
i'm using xdoclet-hibernate-module-1.2.1 and have troubles with the composite-id.
Here's what i wrote :
/**
* The primary key class
*
* no hibernate tag here ?
*/
public class FooPK implements Serializable {
private String field1;
private String field2;
/**
* @hibernate.property
* column="field1"
*/
public String getField1() { ... }
public void setField1(...) { ... }
/**
* @hibernate.property
* column="field2"
*/
// same stuff
...
public int hashCode() { ... }
public boolean equals(Object o) { ... }
}

/**
* The entity class
*
* @hibernate.class
* table="foo"
*/
public class Foo {
private FooPK pk;
...
/**
* @hibernate.id
* generator-class="assigned"
*/
public FooPK getPK() { return pk; }
public void setPK(FooPK pk) { this.pk = pk; }
...
}

so, i get a "xdoclet.template.TemplateException: Invoking method in class xdoclet.modules.hibernate.HibernateTagsHandler failed: ifHasCompositeId, line=132...."
when generating mapping file for Foo.

what do i miss?

regards


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.