Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristopher Frost2012-08-21 09:11:07 +0000
committerChristopher Frost2012-08-21 09:11:07 +0000
commit09bb319dd6558c04d9c0a40b04d6f538829f43d0 (patch)
treed1798bd8a1aea5ecd19e7a9f68d0ef8ebe5cdf7f /org.eclipse.virgo.kernel.deployer.test/src/test
parent866c705f135154788ad72aaafb61fb7139097ead (diff)
downloadorg.eclipse.virgo.kernel-09bb319dd6558c04d9c0a40b04d6f538829f43d0.tar.gz
org.eclipse.virgo.kernel-09bb319dd6558c04d9c0a40b04d6f538829f43d0.tar.xz
org.eclipse.virgo.kernel-09bb319dd6558c04d9c0a40b04d6f538829f43d0.zip
387631 Removing old bespoke Version class which isnt being used in any way that osgi Version cant
Diffstat (limited to 'org.eclipse.virgo.kernel.deployer.test/src/test')
-rw-r--r--org.eclipse.virgo.kernel.deployer.test/src/test/java/org/eclipse/virgo/kernel/deployer/test/modules/TesterModule.java7
-rw-r--r--org.eclipse.virgo.kernel.deployer.test/src/test/java/org/eclipse/virgo/kernel/deployer/test/modules/TesterModuleExport.java10
-rw-r--r--org.eclipse.virgo.kernel.deployer.test/src/test/resources/META-INF/MANIFEST.MF1
3 files changed, 9 insertions, 9 deletions
diff --git a/org.eclipse.virgo.kernel.deployer.test/src/test/java/org/eclipse/virgo/kernel/deployer/test/modules/TesterModule.java b/org.eclipse.virgo.kernel.deployer.test/src/test/java/org/eclipse/virgo/kernel/deployer/test/modules/TesterModule.java
index fb7d30ee..00e80792 100644
--- a/org.eclipse.virgo.kernel.deployer.test/src/test/java/org/eclipse/virgo/kernel/deployer/test/modules/TesterModule.java
+++ b/org.eclipse.virgo.kernel.deployer.test/src/test/java/org/eclipse/virgo/kernel/deployer/test/modules/TesterModule.java
@@ -16,7 +16,7 @@ import java.util.HashSet;
import java.util.List;
import java.util.Set;
-import org.eclipse.virgo.kernel.osgi.common.Version;
+import org.osgi.framework.Version;
/**
@@ -30,13 +30,14 @@ import org.eclipse.virgo.kernel.osgi.common.Version;
public class TesterModule {
private final String moduleName;
private final Version moduleVersion;
+ public static final Version MINIMUM_VERSION = new Version("0");
private final Set<TesterModuleImport> moduleImports;
private final Set<TesterModuleExport> moduleExports;
public static class Builder {
private final String moduleName;
- private Version moduleVersion = Version.MINIMUM_VERSION;
+ private Version moduleVersion = MINIMUM_VERSION;
private Set<TesterModuleImport> moduleImports = new HashSet<TesterModuleImport>();
private Set<TesterModuleExport> moduleExports = new HashSet<TesterModuleExport>();
@@ -96,7 +97,7 @@ public class TesterModule {
hdrs.add("Bundle-ManifestVersion: 2");
hdrs.add("Bundle-Name: TesterModule-" + this.moduleName);
hdrs.add("Bundle-SymbolicName: " + this.moduleName);
- if (!this.moduleVersion.equals(Version.MINIMUM_VERSION)) {
+ if (!this.moduleVersion.equals(MINIMUM_VERSION)) {
hdrs.add("Bundle-Version: " + this.moduleVersion);
}
if (!this.moduleExports.isEmpty()) {
diff --git a/org.eclipse.virgo.kernel.deployer.test/src/test/java/org/eclipse/virgo/kernel/deployer/test/modules/TesterModuleExport.java b/org.eclipse.virgo.kernel.deployer.test/src/test/java/org/eclipse/virgo/kernel/deployer/test/modules/TesterModuleExport.java
index 368db077..8fc376a0 100644
--- a/org.eclipse.virgo.kernel.deployer.test/src/test/java/org/eclipse/virgo/kernel/deployer/test/modules/TesterModuleExport.java
+++ b/org.eclipse.virgo.kernel.deployer.test/src/test/java/org/eclipse/virgo/kernel/deployer/test/modules/TesterModuleExport.java
@@ -17,8 +17,7 @@ import java.util.Map;
import java.util.Set;
import java.util.Map.Entry;
-import org.eclipse.virgo.kernel.osgi.common.Version;
-
+import org.osgi.framework.Version;
/**
* Export for a {@link TesterModule}
* <p />
@@ -28,7 +27,8 @@ import org.eclipse.virgo.kernel.osgi.common.Version;
*/
public class TesterModuleExport {
private static final String HEADER_ENTRY_CLAUSE_SEPARATOR = ";";
- private static final String HEADER_ENTRY_ATTRIBUTE_NAME_SEPARATOR = ",";
+ private static final String HEADER_ENTRY_ATTRIBUTE_NAME_SEPARATOR = ",";
+ public static final Version MINIMUM_VERSION = new Version("0");
private final String pkgName;
private final Version pkgVersion;
private final Map<String,String> pkgAttributes;
@@ -39,7 +39,7 @@ public class TesterModuleExport {
//Required parameters
private final String pkgName;
//Optional parameters
- private Version pkgVersion = Version.MINIMUM_VERSION;
+ private Version pkgVersion = MINIMUM_VERSION;
private Map<String,String> pkgAttributes = new HashMap<String,String>();
private Set<String> pkgMandatoryAttributes = new HashSet<String>();
private Set<String> pkgUses = new HashSet<String>();
@@ -95,7 +95,7 @@ public class TesterModuleExport {
public String headerEntry() {
StringBuffer sb = new StringBuffer(this.pkgName);
- if (!this.pkgVersion.equals(Version.MINIMUM_VERSION)) {
+ if (!this.pkgVersion.equals(MINIMUM_VERSION)) {
sb.append(HEADER_ENTRY_CLAUSE_SEPARATOR).append(versionClause(this.pkgVersion));
}
if (!this.pkgAttributes.isEmpty()) {
diff --git a/org.eclipse.virgo.kernel.deployer.test/src/test/resources/META-INF/MANIFEST.MF b/org.eclipse.virgo.kernel.deployer.test/src/test/resources/META-INF/MANIFEST.MF
index 4974ca86..f4817a84 100644
--- a/org.eclipse.virgo.kernel.deployer.test/src/test/resources/META-INF/MANIFEST.MF
+++ b/org.eclipse.virgo.kernel.deployer.test/src/test/resources/META-INF/MANIFEST.MF
@@ -10,7 +10,6 @@ Import-Package: org.eclipse.virgo.nano.core,
org.eclipse.virgo.kernel.model,
org.eclipse.virgo.kernel.model.management,
org.eclipse.virgo.kernel.module,
- org.eclipse.virgo.kernel.osgi.common,
org.eclipse.virgo.kernel.osgi.framework,
org.eclipse.equinox.region,
org.eclipse.virgo.kernel.services.work,

Back to the top