Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Rapicault2009-12-10 15:14:54 +0000
committerPascal Rapicault2009-12-10 15:14:54 +0000
commit2ba559a712c9dedb7ab901b8d2d09582e9ac9038 (patch)
treeb84a8cc3e18487576f942b28baab48046fb0feb3
parent7f19b779295b1779c095f4234da61d96ce96a5fc (diff)
downloadrt.equinox.p2-2ba559a712c9dedb7ab901b8d2d09582e9ac9038.tar.gz
rt.equinox.p2-2ba559a712c9dedb7ab901b8d2d09582e9ac9038.tar.xz
rt.equinox.p2-2ba559a712c9dedb7ab901b8d2d09582e9ac9038.zip
Fix the check for fragment
-rw-r--r--bundles/org.eclipse.equinox.p2.metadata/src/org/eclipse/equinox/p2/metadata/query/FragmentQuery.java9
1 files changed, 6 insertions, 3 deletions
diff --git a/bundles/org.eclipse.equinox.p2.metadata/src/org/eclipse/equinox/p2/metadata/query/FragmentQuery.java b/bundles/org.eclipse.equinox.p2.metadata/src/org/eclipse/equinox/p2/metadata/query/FragmentQuery.java
index 01026ffe7..6d8cfb907 100644
--- a/bundles/org.eclipse.equinox.p2.metadata/src/org/eclipse/equinox/p2/metadata/query/FragmentQuery.java
+++ b/bundles/org.eclipse.equinox.p2.metadata/src/org/eclipse/equinox/p2/metadata/query/FragmentQuery.java
@@ -10,6 +10,7 @@
*******************************************************************************/
package org.eclipse.equinox.p2.metadata.query;
+import org.eclipse.equinox.internal.provisional.p2.metadata.IInstallableUnitFragment;
import org.eclipse.equinox.internal.provisional.p2.metadata.query.IUPropertyQuery;
import org.eclipse.equinox.internal.provisional.p2.metadata.query.MatchQuery;
import org.eclipse.equinox.p2.metadata.IInstallableUnit;
@@ -33,12 +34,14 @@ public final class FragmentQuery extends MatchQuery {
/**
* Test if the {@link IInstallableUnit} is a fragment.
* @param iu the element being tested.
- * @return <tt>true</tt> if the parameter is a group.
+ * @return <tt>true</tt> if the parameter is a fragment.
*/
public static boolean isFragment(IInstallableUnit iu) {
- String value = iu.getProperty(PROP_TYPE_FRAGMENT);
- if (value != null && (value.equals(Boolean.TRUE.toString())))
+ if (iu instanceof IInstallableUnitFragment)
return true;
+ // String value = iu.getProperty(PROP_TYPE_FRAGMENT);
+ // if (value != null && (value.equals(Boolean.TRUE.toString())))
+ // return true;
return false;
}
}

Back to the top