}
// Add the dependencies in a /lib
if (resolver.hasRuntimeDependencies()) {
// check if at root level, there already exists a /lib folder
ModuleFolder libFolder = createLibFolder(members);
List<String> dependencies = resolver
.getRuntimeDependencyLocations();
List<IModuleResource> libMembers = new ArrayList<IModuleResource>();
for (String path : dependencies) {
addModuleResources(path, libMembers,
JavaStartCommand.DEFAULT_LIB_PATH);
}
if (!libMembers.isEmpty()) {
libFolder.setMembers(libMembers
.toArray(new IModuleResource[0]));
}
}
}
return members.toArray(new IModuleResource[0]);