summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEike Stepper2006-08-22 09:48:30 (EDT)
committerEike Stepper2006-08-22 09:48:30 (EDT)
commit295816aeecff3d02f26f4d4ccad67be11ea20fe1 (patch)
treecb8ca75c4977d9d3d48929109eab0b944a7650ac
parent9e5a6dab72136d47a9293a0e79f859dd5b86c60b (diff)
downloadcdo-295816aeecff3d02f26f4d4ccad67be11ea20fe1.zip
cdo-295816aeecff3d02f26f4d4ccad67be11ea20fe1.tar.gz
cdo-295816aeecff3d02f26f4d4ccad67be11ea20fe1.tar.bz2
[151560] Query Language for CDO
https://bugs.eclipse.org/bugs/show_bug.cgi?id=151560
-rw-r--r--plugins/org.eclipse.emf.cdo.tests/META-INF/MANIFEST.MF3
-rw-r--r--plugins/org.eclipse.emf.cdo.tests/src/org/eclipse/emf/cdo/tests/model1/ExtentTest.java25
2 files changed, 4 insertions, 24 deletions
diff --git a/plugins/org.eclipse.emf.cdo.tests/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.cdo.tests/META-INF/MANIFEST.MF
index 5f41225..d61aa1a 100644
--- a/plugins/org.eclipse.emf.cdo.tests/META-INF/MANIFEST.MF
+++ b/plugins/org.eclipse.emf.cdo.tests/META-INF/MANIFEST.MF
@@ -13,4 +13,5 @@ Require-Bundle: org.eclipse.core.runtime,
org.eclipse.emf.cdo.client,
org.eclipse.emf.cdo.server,
org.eclipse.net4j.embedded,
- org.eclipse.net4j.socket
+ org.eclipse.net4j.socket,
+ org.eclipse.emf.cdo.client.ocl
diff --git a/plugins/org.eclipse.emf.cdo.tests/src/org/eclipse/emf/cdo/tests/model1/ExtentTest.java b/plugins/org.eclipse.emf.cdo.tests/src/org/eclipse/emf/cdo/tests/model1/ExtentTest.java
index f6d6ffa..066fad1 100644
--- a/plugins/org.eclipse.emf.cdo.tests/src/org/eclipse/emf/cdo/tests/model1/ExtentTest.java
+++ b/plugins/org.eclipse.emf.cdo.tests/src/org/eclipse/emf/cdo/tests/model1/ExtentTest.java
@@ -12,14 +12,7 @@ package org.eclipse.emf.cdo.tests.model1;
import org.eclipse.emf.cdo.client.CDOResource;
-import org.eclipse.emf.cdo.client.ClassInfo;
-import org.eclipse.emf.cdo.client.PackageManager;
import org.eclipse.emf.cdo.client.ResourceManager;
-import org.eclipse.emf.cdo.client.protocol.ClientCDOProtocolImpl;
-
-import org.eclipse.emf.ecore.EClass;
-
-import org.eclipse.net4j.core.Channel;
import testmodel1.ExtendedNode;
import testmodel1.TestModel1Package;
@@ -43,14 +36,7 @@ public class ExtentTest extends AbstractModel1Test
CDOResource resource = saveRoot(root, RESOURCE);
ResourceManager resourceManager = resource.getResourceManager();
- Channel channel = resourceManager.getChannel();
-
- PackageManager packageManager = resourceManager.getPackageManager();
- EClass eClass = TestModel1Package.eINSTANCE.getTreeNode();
- ClassInfo classInfo = packageManager.getClassInfo(eClass);
- int cid = classInfo.getCID();
-
- Set extent = ClientCDOProtocolImpl.requestQueryExtent(channel, cid, true);
+ Set extent = resourceManager.queryExtent(TestModel1Package.eINSTANCE.getTreeNode());
assertEquals(1 + CHILDREN.length, extent.size());
assertTrue(extent.contains(root));
@@ -76,14 +62,7 @@ public class ExtentTest extends AbstractModel1Test
CDOResource resource = saveRoot(root, RESOURCE);
ResourceManager resourceManager = resource.getResourceManager();
- Channel channel = resourceManager.getChannel();
-
- PackageManager packageManager = resourceManager.getPackageManager();
- EClass eClass = TestModel1Package.eINSTANCE.getTreeNode();
- ClassInfo classInfo = packageManager.getClassInfo(eClass);
- int cid = classInfo.getCID();
-
- Set extent = ClientCDOProtocolImpl.requestQueryExtent(channel, cid, false);
+ Set extent = resourceManager.queryExtent(TestModel1Package.eINSTANCE.getTreeNode(), true, null);
assertEquals(2 + CHILDREN.length, extent.size());
assertTrue(extent.contains(root));