Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortle2008-09-23 04:06:04 +0000
committertle2008-09-23 04:06:04 +0000
commit224b68661af5ee8535a785ddee457618cc005a56 (patch)
tree1ec88992d7a4a7688004d3f8ab475479acb5e43a /jpa/plugins
parent02912da5e49d82a777e61239fa1518b74c2e5fde (diff)
downloadwebtools.dali-224b68661af5ee8535a785ddee457618cc005a56.tar.gz
webtools.dali-224b68661af5ee8535a785ddee457618cc005a56.tar.xz
webtools.dali-224b68661af5ee8535a785ddee457618cc005a56.zip
231539 - "Null" table and join column messages
Diffstat (limited to 'jpa/plugins')
-rw-r--r--jpa/plugins/org.eclipse.jpt.core/property_files/jpa_validation.properties2
-rw-r--r--jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/java/GenericJavaJoinTable.java5
-rw-r--r--jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/orm/GenericOrmJoinTable.java5
-rw-r--r--jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/validation/JpaValidationMessages.java2
4 files changed, 8 insertions, 6 deletions
diff --git a/jpa/plugins/org.eclipse.jpt.core/property_files/jpa_validation.properties b/jpa/plugins/org.eclipse.jpt.core/property_files/jpa_validation.properties
index f7ad36283a..1b8bb734c6 100644
--- a/jpa/plugins/org.eclipse.jpt.core/property_files/jpa_validation.properties
+++ b/jpa/plugins/org.eclipse.jpt.core/property_files/jpa_validation.properties
@@ -52,7 +52,7 @@ JOIN_TABLE_UNRESOLVED_CATALOG=Catalog \"{0}\" cannot be resolved for join table
JOIN_TABLE_UNRESOLVED_SCHEMA=Schema \"{0}\" cannot be resolved for join table \"{1}\"
VIRTUAL_ATTRIBUTE_JOIN_TABLE_UNRESOLVED_CATALOG=In implied attribute \"{0}\", catalog \"{1}\" cannot be resolved for join table \"{2}\"
VIRTUAL_ATTRIBUTE_JOIN_TABLE_UNRESOLVED_SCHEMA=In implied attribute \"{0}\", schema \"{1}\" cannot be resolved for join table \"{2}\"
-JOIN_TABLE_UNRESOLVED_NAME=Join table \"{0}\" cannot be resolved
+JOIN_TABLE_CANNOT_BE_DETERMINED=Target Entity for \"{0}\" not defined - join table cannot be determined
VIRTUAL_ATTRIBUTE_JOIN_TABLE_UNRESOLVED_NAME=In implied attribute \"{0}\", join table \"{1}\" cannot be resolved
COLUMN_UNRESOLVED_TABLE=Table \"{0}\" for column \"{1}\" cannot be resolved
VIRTUAL_ATTRIBUTE_COLUMN_UNRESOLVED_TABLE=In implied attribute \"{0}\", table \"{1}\" for column \"{2}\" cannot be resolved
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 0dde641c19..a0c6568e3a 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
@@ -538,11 +538,12 @@ public class GenericJavaJoinTable
}
if ( ! this.isResolved()) {
+ String attributeName = this.getRelationshipMapping().getPersistentAttribute().getName();
messages.add(
DefaultJpaValidationMessages.buildMessage(
IMessage.HIGH_SEVERITY,
- JpaValidationMessages.JOIN_TABLE_UNRESOLVED_NAME,
- new String[] {this.getName()},
+ JpaValidationMessages.JOIN_TABLE_CANNOT_BE_DETERMINED,
+ new String[] {attributeName},
this,
this.getNameTextRange(astRoot))
);
diff --git a/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/orm/GenericOrmJoinTable.java b/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/orm/GenericOrmJoinTable.java
index 5d6fd8a260..17dbde1582 100644
--- a/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/orm/GenericOrmJoinTable.java
+++ b/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/context/orm/GenericOrmJoinTable.java
@@ -540,11 +540,12 @@ public class GenericOrmJoinTable
);
}
else {
+ String attributeName = mapping.getPersistentAttribute().getName();
messages.add(
DefaultJpaValidationMessages.buildMessage(
IMessage.HIGH_SEVERITY,
- JpaValidationMessages.JOIN_TABLE_UNRESOLVED_NAME,
- new String[] {this.getName()},
+ JpaValidationMessages.JOIN_TABLE_CANNOT_BE_DETERMINED,
+ new String[] {attributeName},
this,
this.getNameTextRange())
);
diff --git a/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/validation/JpaValidationMessages.java b/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/validation/JpaValidationMessages.java
index 303902d496..d47457bf39 100644
--- a/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/validation/JpaValidationMessages.java
+++ b/jpa/plugins/org.eclipse.jpt.core/src/org/eclipse/jpt/core/internal/validation/JpaValidationMessages.java
@@ -58,7 +58,7 @@ public interface JpaValidationMessages {
public static final String JOIN_TABLE_UNRESOLVED_SCHEMA = "JOIN_TABLE_UNRESOLVED_SCHEMA";
public static final String VIRTUAL_ATTRIBUTE_JOIN_TABLE_UNRESOLVED_CATALOG = "VIRTUAL_ATTRIBUTE_JOIN_TABLE_UNRESOLVED_CATALOG";
public static final String VIRTUAL_ATTRIBUTE_JOIN_TABLE_UNRESOLVED_SCHEMA = "VIRTUAL_ATTRIBUTE_JOIN_TABLE_UNRESOLVED_SCHEMA";
- public static final String JOIN_TABLE_UNRESOLVED_NAME = "JOIN_TABLE_UNRESOLVED_NAME";
+ public static final String JOIN_TABLE_CANNOT_BE_DETERMINED = "JOIN_TABLE_CANNOT_BE_DETERMINED";
public static final String VIRTUAL_ATTRIBUTE_JOIN_TABLE_UNRESOLVED_NAME = "VIRTUAL_ATTRIBUTE_JOIN_TABLE_UNRESOLVED_NAME";
public static final String COLUMN_UNRESOLVED_TABLE = "COLUMN_UNRESOLVED_TABLE";
public static final String VIRTUAL_ATTRIBUTE_COLUMN_UNRESOLVED_TABLE = "VIRTUAL_ATTRIBUTE_COLUMN_UNRESOLVED_TABLE";

Back to the top