diff options
author | kmoore | 2008-12-09 14:53:23 +0000 |
---|---|---|
committer | kmoore | 2008-12-09 14:53:23 +0000 |
commit | d0571d5bd5482dd6e6a2fd1d5f766e7957aa83e8 (patch) | |
tree | 1b4b8b72b26c36f3a0959dfa8e3119e27d9024df /jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/java/GenericJavaJoinTable.java | |
parent | 9979ddd04df6150fc5222168333fbf67a27c17c1 (diff) | |
download | webtools.dali-d0571d5bd5482dd6e6a2fd1d5f766e7957aa83e8.tar.gz webtools.dali-d0571d5bd5482dd6e6a2fd1d5f766e7957aa83e8.tar.xz webtools.dali-d0571d5bd5482dd6e6a2fd1d5f766e7957aa83e8.zip |
257629 - Invalid Problem reported for multi-relationship mapping when join table doesn't resolve
Diffstat (limited to 'jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/java/GenericJavaJoinTable.java')
-rw-r--r-- | jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/java/GenericJavaJoinTable.java | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/java/GenericJavaJoinTable.java b/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/java/GenericJavaJoinTable.java index c3f231dda0..c675304bf4 100644 --- a/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/java/GenericJavaJoinTable.java +++ b/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/java/GenericJavaJoinTable.java @@ -539,16 +539,16 @@ public class GenericJavaJoinTable } if ( ! this.isResolved()) { - String attributeName = this.getRelationshipMapping().getPersistentAttribute().getName(); - messages.add( - DefaultJpaValidationMessages.buildMessage( - IMessage.HIGH_SEVERITY, - JpaValidationMessages.JOIN_TABLE_CANNOT_BE_DETERMINED, - new String[] {attributeName}, - this, - this.getNameTextRange(astRoot) - ) - ); + if (getName() != null) { //if name is null, the validation will be handled elsewhere, such as the target entity is not defined + messages.add( + DefaultJpaValidationMessages.buildMessage( + IMessage.HIGH_SEVERITY, + JpaValidationMessages.JOIN_TABLE_UNRESOLVED_NAME, + new String[] {this.getName()}, + this, + this.getNameTextRange(astRoot)) + ); + } return; } |