mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-06-08 10:16:03 +02:00
provide a sourcemapper per project
This commit is contained in:
parent
d0d01cd58e
commit
43fdcb2dc6
1 changed files with 16 additions and 0 deletions
|
@ -93,6 +93,11 @@ public class CModelManager implements IResourceChangeListener {
|
||||||
* The list of started BinaryRunners on projects.
|
* The list of started BinaryRunners on projects.
|
||||||
*/
|
*/
|
||||||
private HashMap binaryRunners = new HashMap();
|
private HashMap binaryRunners = new HashMap();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The lis of the SourceMappers on projects.
|
||||||
|
*/
|
||||||
|
private HashMap sourceMappers = new HashMap();
|
||||||
|
|
||||||
public static final String [] sourceExtensions = {"c", "cxx", "cc", "C", "cpp"};
|
public static final String [] sourceExtensions = {"c", "cxx", "cc", "C", "cpp"};
|
||||||
|
|
||||||
|
@ -498,6 +503,17 @@ public class CModelManager implements IResourceChangeListener {
|
||||||
return runner;
|
return runner;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public SourceMapper getSourceMapper(ICProject cProject) {
|
||||||
|
SourceMapper mapper = null;
|
||||||
|
synchronized(sourceMappers) {
|
||||||
|
mapper = (SourceMapper) sourceMappers.get(cProject);
|
||||||
|
if (mapper == null) {
|
||||||
|
mapper = new SourceMapper(cProject);
|
||||||
|
sourceMappers.put(cProject, mapper);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return mapper;
|
||||||
|
}
|
||||||
/**
|
/**
|
||||||
* addElementChangedListener method comment.
|
* addElementChangedListener method comment.
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Add table
Reference in a new issue