Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpfilion2012-01-27 21:54:34 +0000
committerpfilion2012-01-27 21:54:34 +0000
commitde7f520808c359d44b7afe3a68d5209300f47a63 (patch)
treea759406ff10d7aaf514ca8556a7b97f95dccbd71 /jpa/tests/org.eclipse.jpt.jpa.core.tests.extension.resource
parent4f66da80db23970998eac10b4609461a2b84193d (diff)
downloadwebtools.dali-de7f520808c359d44b7afe3a68d5209300f47a63.tar.gz
webtools.dali-de7f520808c359d44b7afe3a68d5209300f47a63.tar.xz
webtools.dali-de7f520808c359d44b7afe3a68d5209300f47a63.zip
Refactored Hermes integration, JpaPlatform now returns the JPQL grammar and not the helper
Diffstat (limited to 'jpa/tests/org.eclipse.jpt.jpa.core.tests.extension.resource')
-rw-r--r--jpa/tests/org.eclipse.jpt.jpa.core.tests.extension.resource/src/org/eclipse/jpt/jpa/core/tests/extension/resource/TestJpaJpqlQueryHelper.java86
-rw-r--r--jpa/tests/org.eclipse.jpt.jpa.core.tests.extension.resource/src/org/eclipse/jpt/jpa/core/tests/extension/resource/TestJpaPlatformFactory.java6
2 files changed, 3 insertions, 89 deletions
diff --git a/jpa/tests/org.eclipse.jpt.jpa.core.tests.extension.resource/src/org/eclipse/jpt/jpa/core/tests/extension/resource/TestJpaJpqlQueryHelper.java b/jpa/tests/org.eclipse.jpt.jpa.core.tests.extension.resource/src/org/eclipse/jpt/jpa/core/tests/extension/resource/TestJpaJpqlQueryHelper.java
deleted file mode 100644
index c14292c265..0000000000
--- a/jpa/tests/org.eclipse.jpt.jpa.core.tests.extension.resource/src/org/eclipse/jpt/jpa/core/tests/extension/resource/TestJpaJpqlQueryHelper.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2011 Oracle. All rights reserved.
- * This program and the accompanying materials are made available under the
- * terms of the Eclipse Public License v1.0 and Eclipse Distribution License v. 1.0
- * which accompanies this distribution.
- * The Eclipse Public License is available at http://www.eclipse.org/legal/epl-v10.html
- * and the Eclipse Distribution License is available at
- * http://www.eclipse.org/org/documents/edl-v10.php.
- *
- * Contributors:
- * Oracle - initial API and implementation
- *
- ******************************************************************************/
-package org.eclipse.jpt.jpa.core.tests.extension.resource;
-
-import org.eclipse.jpt.jpa.core.jpql.JpaJpqlQueryHelper;
-import org.eclipse.jpt.jpa.core.jpql.spi.JpaManagedTypeProvider;
-
-import org.eclipse.jpt.jpa.core.context.NamedQuery;
-import org.eclipse.persistence.jpa.jpql.AbstractContentAssistVisitor;
-import org.eclipse.persistence.jpa.jpql.AbstractGrammarValidator;
-import org.eclipse.persistence.jpa.jpql.AbstractSemanticValidator;
-import org.eclipse.persistence.jpa.jpql.JPQLQueryContext;
-import org.eclipse.persistence.jpa.jpql.parser.JPQLGrammar;
-import org.eclipse.persistence.jpa.jpql.parser.JPQLGrammar2_0;
-
-/**
- * @version 3.1
- * @since 3.1
- * @author Pascal Filion
- */
-public class TestJpaJpqlQueryHelper extends JpaJpqlQueryHelper {
-
- private static final JpaJpqlQueryHelper INSTANCE = new TestJpaJpqlQueryHelper();
-
- /**
- * Creates a new <code>TestJpaJpqlQueryHelper</code>.
- */
- public TestJpaJpqlQueryHelper() {
- super(JPQLGrammar2_0.instance());
- }
-
- public static JpaJpqlQueryHelper instance() {
- return INSTANCE;
- }
-
- /**
- * {@inheritDoc}
- */
- @Override
- protected AbstractContentAssistVisitor buildContentAssistVisitor(JPQLQueryContext queryContext) {
- return null;
- }
-
- /**
- * {@inheritDoc}
- */
- @Override
- protected AbstractGrammarValidator buildGrammarValidator(JPQLQueryContext queryContext) {
- return null;
- }
-
- /**
- * {@inheritDoc}
- */
- @Override
- protected JPQLQueryContext buildJPQLQueryContext(JPQLGrammar jpqlGrammar) {
- return null;
- }
-
- /**
- * {@inheritDoc}
- */
- @Override
- public JpaManagedTypeProvider buildProvider(NamedQuery query) {
- return null;
- }
-
- /**
- * {@inheritDoc}
- */
- @Override
- protected AbstractSemanticValidator buildSemanticValidator(JPQLQueryContext queryContext) {
- return null;
- }
-} \ No newline at end of file
diff --git a/jpa/tests/org.eclipse.jpt.jpa.core.tests.extension.resource/src/org/eclipse/jpt/jpa/core/tests/extension/resource/TestJpaPlatformFactory.java b/jpa/tests/org.eclipse.jpt.jpa.core.tests.extension.resource/src/org/eclipse/jpt/jpa/core/tests/extension/resource/TestJpaPlatformFactory.java
index b5ed1face7..d148ddcbc5 100644
--- a/jpa/tests/org.eclipse.jpt.jpa.core.tests.extension.resource/src/org/eclipse/jpt/jpa/core/tests/extension/resource/TestJpaPlatformFactory.java
+++ b/jpa/tests/org.eclipse.jpt.jpa.core.tests.extension.resource/src/org/eclipse/jpt/jpa/core/tests/extension/resource/TestJpaPlatformFactory.java
@@ -19,6 +19,7 @@ import org.eclipse.jpt.jpa.core.internal.GenericJpaAnnotationDefinitionProvider;
import org.eclipse.jpt.jpa.core.internal.GenericJpaPlatform;
import org.eclipse.jpt.jpa.core.internal.GenericJpaPlatformFactory.SimpleVersion;
import org.eclipse.jpt.jpa.core.internal.JpaAnnotationProvider;
+import org.eclipse.persistence.jpa.jpql.parser.DefaultJPQLGrammar;
/**
* All the state in the JPA platform should be "static" (i.e. unchanging once
@@ -35,7 +36,6 @@ public class TestJpaPlatformFactory
super();
}
-
public JpaPlatform buildJpaPlatform(String id) {
return new GenericJpaPlatform(
id,
@@ -44,7 +44,7 @@ public class TestJpaPlatformFactory
new JpaAnnotationProvider(GenericJpaAnnotationDefinitionProvider.instance()),
TestJpaPlatformProvider.instance(),
buildJpaPlatformVariation(),
- TestJpaJpqlQueryHelper.instance());
+ DefaultJPQLGrammar.instance());
}
private JpaPlatform.Version buildJpaVersion() {
@@ -69,4 +69,4 @@ public class TestJpaPlatformFactory
}
};
}
-}
+} \ No newline at end of file

Back to the top