|
Lines 10-23
Link Here
|
| 10 |
*******************************************************************************/ |
10 |
*******************************************************************************/ |
| 11 |
package org.eclipse.pde.internal.build.publisher.compatibility; |
11 |
package org.eclipse.pde.internal.build.publisher.compatibility; |
| 12 |
|
12 |
|
| 13 |
import org.eclipse.equinox.p2.metadata.IInstallableUnit; |
|
|
| 14 |
|
| 15 |
import org.eclipse.core.runtime.*; |
13 |
import org.eclipse.core.runtime.*; |
| 16 |
import org.eclipse.equinox.internal.p2.publisher.eclipse.ProductFile; |
14 |
import org.eclipse.equinox.internal.p2.publisher.eclipse.ProductFile; |
| 17 |
import org.eclipse.equinox.internal.provisional.p2.metadata.*; |
15 |
import org.eclipse.equinox.internal.provisional.p2.metadata.MetadataFactory; |
|
|
16 |
import org.eclipse.equinox.internal.provisional.p2.metadata.Version; |
| 18 |
import org.eclipse.equinox.internal.provisional.p2.metadata.MetadataFactory.InstallableUnitDescription; |
17 |
import org.eclipse.equinox.internal.provisional.p2.metadata.MetadataFactory.InstallableUnitDescription; |
| 19 |
import org.eclipse.equinox.internal.provisional.p2.metadata.query.Collector; |
|
|
| 20 |
import org.eclipse.equinox.internal.provisional.p2.metadata.query.MatchQuery; |
18 |
import org.eclipse.equinox.internal.provisional.p2.metadata.query.MatchQuery; |
|
|
19 |
import org.eclipse.equinox.p2.metadata.IInstallableUnit; |
| 20 |
import org.eclipse.equinox.p2.metadata.query.IQueryResult; |
| 21 |
import org.eclipse.equinox.p2.publisher.*; |
21 |
import org.eclipse.equinox.p2.publisher.*; |
| 22 |
import org.eclipse.equinox.p2.publisher.actions.RootFilesAction; |
22 |
import org.eclipse.equinox.p2.publisher.actions.RootFilesAction; |
| 23 |
import org.eclipse.pde.internal.build.IPDEBuildConstants; |
23 |
import org.eclipse.pde.internal.build.IPDEBuildConstants; |
|
Lines 54-61
Link Here
|
| 54 |
} |
54 |
} |
| 55 |
}; |
55 |
}; |
| 56 |
|
56 |
|
| 57 |
Collector collector = query.perform(results.getIUs(null, IPublisherResult.NON_ROOT).iterator(), new Collector()); |
57 |
IQueryResult collector = query.perform(results.getIUs(null, IPublisherResult.NON_ROOT).iterator()); |
| 58 |
InstallableUnitDescription descriptor = createParentIU(collector.toCollection(), RootFilesAction.computeIUId(baseId, flavor), Version.parseVersion(version)); |
58 |
InstallableUnitDescription descriptor = createParentIU(collector.unmodifiableSet(), RootFilesAction.computeIUId(baseId, flavor), Version.parseVersion(version)); |
| 59 |
descriptor.setSingleton(true); |
59 |
descriptor.setSingleton(true); |
| 60 |
IInstallableUnit rootIU = MetadataFactory.createInstallableUnit(descriptor); |
60 |
IInstallableUnit rootIU = MetadataFactory.createInstallableUnit(descriptor); |
| 61 |
results.addIU(rootIU, IPublisherResult.ROOT); |
61 |
results.addIU(rootIU, IPublisherResult.ROOT); |