diff options
author | Thomas Watson | 2013-07-17 19:50:43 +0000 |
---|---|---|
committer | Thomas Watson | 2013-07-17 19:50:43 +0000 |
commit | 74dbf9088435ef5cfed74f1265f7509f7472c5cd (patch) | |
tree | f53ec7a35f61983ae7f73e50c79c675065d759ac /bundles/org.eclipse.osgi/osgi/src/org | |
parent | c69fb93ba222407913cb7800585edbe18a8467fc (diff) | |
download | rt.equinox.framework-74dbf9088435ef5cfed74f1265f7509f7472c5cd.tar.gz rt.equinox.framework-74dbf9088435ef5cfed74f1265f7509f7472c5cd.tar.xz rt.equinox.framework-74dbf9088435ef5cfed74f1265f7509f7472c5cd.zip |
Update to latest OSGi R6 core APII20130717-1600
Diffstat (limited to 'bundles/org.eclipse.osgi/osgi/src/org')
-rw-r--r-- | bundles/org.eclipse.osgi/osgi/src/org/osgi/framework/VersionRange.java | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/bundles/org.eclipse.osgi/osgi/src/org/osgi/framework/VersionRange.java b/bundles/org.eclipse.osgi/osgi/src/org/osgi/framework/VersionRange.java index 7106211ca..3cc252688 100644 --- a/bundles/org.eclipse.osgi/osgi/src/org/osgi/framework/VersionRange.java +++ b/bundles/org.eclipse.osgi/osgi/src/org/osgi/framework/VersionRange.java @@ -476,9 +476,16 @@ public class VersionRange { } StringBuffer result = new StringBuffer(128); - if (right != null) { + final boolean needPresence = !leftClosed && ((right == null) || !rightClosed); + final boolean multipleTerms = needPresence || (right != null); + if (multipleTerms) { result.append("(&"); } + if (needPresence) { + result.append('('); + result.append(attributeName); + result.append("=*)"); + } if (leftClosed) { result.append('('); result.append(attributeName); @@ -506,6 +513,8 @@ public class VersionRange { result.append(right.toString0()); result.append("))"); } + } + if (multipleTerms) { result.append(')'); } |