[jboss-cvs] jboss-seam/src/main/org/jboss/seam ...
Peter Muir
peter at bleepbleep.org.uk
Wed Apr 11 16:02:00 EDT 2007
User: pmuir
Date: 07/04/11 16:02:00
Modified: src/main/org/jboss/seam Entity.java
Log:
JBSEAM-1147
Revision Changes Path
1.3 +4 -2 jboss-seam/src/main/org/jboss/seam/Entity.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: Entity.java
===================================================================
RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/Entity.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -b -r1.2 -r1.3
--- Entity.java 27 Feb 2007 15:03:07 -0000 1.2
+++ Entity.java 11 Apr 2007 20:02:00 -0000 1.3
@@ -3,7 +3,9 @@
import java.lang.reflect.Field;
import java.lang.reflect.Method;
+import javax.persistence.EmbeddedId;
import javax.persistence.Id;
+import javax.persistence.IdClass;
import javax.persistence.PostLoad;
import javax.persistence.PrePersist;
import javax.persistence.PreRemove;
@@ -58,7 +60,7 @@
{
postLoadMethod = method;
}
- if ( method.isAnnotationPresent(Id.class) )
+ if ( method.isAnnotationPresent(Id.class) || method.isAnnotationPresent(EmbeddedId.class))
{
identifierGetter = method;
}
@@ -68,7 +70,7 @@
{
for ( Field field: getBeanClass().getDeclaredFields() )
{
- if ( field.isAnnotationPresent(Id.class) )
+ if ( field.isAnnotationPresent(Id.class) || field.isAnnotationPresent(EmbeddedId.class))
{
identifierField = field;
}
More information about the jboss-cvs-commits
mailing list