use of org.eclipse.tycho.core.osgitools.AbstractArtifactDependencyWalker in project tycho by eclipse.
the class ArtifactDependencyWalkerTest method walkProduct.
protected void walkProduct(String productFile, final ArrayList<PluginDescription> plugins, final ArrayList<FeatureDescription> features) throws Exception, IOException, XmlPullParserException {
DependencyArtifacts platform = getTargetPlatform();
final ProductConfiguration product = ProductConfiguration.read(new File(productFile));
ArtifactDependencyWalker walker = new AbstractArtifactDependencyWalker(platform) {
@Override
public void walk(ArtifactDependencyVisitor visitor) {
traverseProduct(product, visitor);
}
};
walker.walk(new ArtifactDependencyVisitor() {
@Override
public void visitPlugin(PluginDescription plugin) {
plugins.add(plugin);
}
@Override
public boolean visitFeature(FeatureDescription feature) {
features.add(feature);
return true;
}
});
}
Aggregations