use of org.erlide.core.builder.BuilderHelper in project erlide_eclipse by erlang.
the class DialyzerUtils method collectFilesAndIncludeDirs.
public static void collectFilesAndIncludeDirs(final Set<IErlModule> modules, final Set<IErlProject> projects, final Collection<String> files, final Collection<String> names, final Collection<IPath> includeDirs, final boolean fromSource) {
for (final IErlModule m : modules) {
final String name = m.getName();
final IErlProject erlProject = ErlangEngine.getInstance().getModelUtilService().getProject(m);
final IProject project = erlProject.getWorkspaceProject();
final IFolder ebin = project.getFolder(erlProject.getProperties().getOutputDir());
if (SourceKind.hasErlExtension(name)) {
if (fromSource) {
final IResource resource = m.getResource();
files.add(resource.getLocation().toPortableString());
} else {
final String moduleName = SystemConfiguration.withoutExtension(name);
final String beamName = moduleName + ".beam";
final IResource beam = ebin.findMember(beamName);
if (beam != null) {
files.add(beam.getLocation().toPortableString());
names.add(moduleName);
}
}
}
}
DialyzerUtils.helper = new BuilderHelper();
for (final IErlProject p : projects) {
includeDirs.addAll(DialyzerUtils.helper.getIncludeDirs(p.getWorkspaceProject()));
}
}
Aggregations