Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(27)

Unified Diff: editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/internal/model/delta/CachedDirectives.java

Issue 8387002: Fix for the DeltaProcessing event when a user changes a library name, inside of a #library(..). I... (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: '' Created 9 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/internal/model/delta/CachedDirectives.java
===================================================================
--- editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/internal/model/delta/CachedDirectives.java (revision 651)
+++ editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/internal/model/delta/CachedDirectives.java (working copy)
@@ -26,13 +26,15 @@
public static final Set<String> EMPTY_STR_SET = Collections.unmodifiableSet(new HashSet<String>(0));
+ private final String libraryName;
+
private final Set<String> imports, sources, resources;
/**
* The empty constructor for {@link CachedDirectives} creates three empty sets.
*/
public CachedDirectives() {
- this(EMPTY_STR_SET, EMPTY_STR_SET, EMPTY_STR_SET);
+ this("", EMPTY_STR_SET, EMPTY_STR_SET, EMPTY_STR_SET);
}
/**
@@ -43,7 +45,9 @@
* @param sources some set of "source" {@link String}s
* @param resources some set of "resource" {@link String}s
*/
- public CachedDirectives(Set<String> imports, Set<String> sources, Set<String> resources) {
+ public CachedDirectives(String libraryName, Set<String> imports, Set<String> sources,
+ Set<String> resources) {
+ this.libraryName = libraryName;
this.imports = Collections.unmodifiableSet(imports);
this.sources = Collections.unmodifiableSet(sources);
this.resources = Collections.unmodifiableSet(resources);
@@ -58,6 +62,14 @@
}
/**
+ * Returns the library name which was created using the <code>libraryName</code> constructor
+ * argument.
+ */
+ public String getLibraryName() {
+ return libraryName;
+ }
+
+ /**
* Returns an unmodifiable {@link Set} which was created using the <code>resources</code>
* constructor argument.
*/

Powered by Google App Engine
This is Rietveld 408576698