}
node = graph.addNode(exportedPackage, startImportPackage);
String[] uses = (String[]) exportedPackage.getDirective("uses");
if (uses != null) {
BundleDescription bundle = exportedPackage.getExporter();
for (String usePackageName : uses) {
// see uses clause points to import or export package
ImportPackageSpecification useImportPackage = findImportPackage(usePackageName, bundle.getImportPackages());
if (useImportPackage == null) {
ExportPackageDescription useExportPackage = findExportPackage(usePackageName, bundle.getExportPackages());
if (useExportPackage == null) {
throw new RuntimeException("No import or export package for an 'uses' package " + usePackageName + " in " + Utils.bundleToString(bundle));
} else {
PackageEdge edge = new PackageEdge(processExportPackage(graph, useExportPackage, startImportPackage));
node.addEdge(edge);