Mercurial > hg > truffle
comparison graal/com.oracle.truffle.api/src/com/oracle/truffle/api/ExecutionContext.java @ 15891:09ac9ac9c4fc
Truffle: SourceManager renamed to SourceFactory
- All methods are static, no longer accessed via ExecutionContext
- Sources are indexed with weak references
- File content caching is now optional; off by default
author | Michael Van De Vanter <michael.van.de.vanter@oracle.com> |
---|---|
date | Sat, 24 May 2014 10:34:43 -0700 |
parents | eb947cc7bff9 |
children | eedf6c293639 |
comparison
equal
deleted
inserted
replaced
15842:eb947cc7bff9 | 15891:09ac9ac9c4fc |
---|---|
37 * <strong>Disclaimer:</strong> this class is under development and will change. | 37 * <strong>Disclaimer:</strong> this class is under development and will change. |
38 */ | 38 */ |
39 public abstract class ExecutionContext { | 39 public abstract class ExecutionContext { |
40 | 40 |
41 private final ProbeManager probeManager = new ProbeManager(); | 41 private final ProbeManager probeManager = new ProbeManager(); |
42 private final SourceManager sourceManager = new SourceManager(); | |
43 private final List<SourceListener> sourceListeners = new ArrayList<>(); | 42 private final List<SourceListener> sourceListeners = new ArrayList<>(); |
44 private Visualizer visualizer = new DefaultVisualizer(); | 43 private Visualizer visualizer = new DefaultVisualizer(); |
45 | 44 |
46 protected ExecutionContext() { | 45 protected ExecutionContext() { |
47 } | 46 } |
59 for (SourceListener listener : sourceListeners) { | 58 for (SourceListener listener : sourceListeners) { |
60 listener.loadEnding(source); | 59 listener.loadEnding(source); |
61 } | 60 } |
62 } | 61 } |
63 }); | 62 }); |
64 } | |
65 | |
66 /** | |
67 * Gets access to source management services. | |
68 */ | |
69 public final SourceManager getSourceManager() { | |
70 return sourceManager; | |
71 } | 63 } |
72 | 64 |
73 /** | 65 /** |
74 * Registers a tool interested in being notified about the loading of {@link Source}s. | 66 * Registers a tool interested in being notified about the loading of {@link Source}s. |
75 */ | 67 */ |