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

Unified Diff: editor/tools/plugins/com.google.dart.server/src/com/google/dart/server/generated/types/RefactoringProblem.java

Issue 496113002: Make RefactoringProblem.location optional. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 4 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
« no previous file with comments | « no previous file | pkg/analysis_server/doc/api.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: editor/tools/plugins/com.google.dart.server/src/com/google/dart/server/generated/types/RefactoringProblem.java
diff --git a/editor/tools/plugins/com.google.dart.server/src/com/google/dart/server/generated/types/RefactoringProblem.java b/editor/tools/plugins/com.google.dart.server/src/com/google/dart/server/generated/types/RefactoringProblem.java
index 88dd815314ecc968f4f776f3855f3aaf86354815..b960ec3f329be507b3ebd2c20718dce5199d8456 100644
--- a/editor/tools/plugins/com.google.dart.server/src/com/google/dart/server/generated/types/RefactoringProblem.java
+++ b/editor/tools/plugins/com.google.dart.server/src/com/google/dart/server/generated/types/RefactoringProblem.java
@@ -49,7 +49,9 @@ public class RefactoringProblem {
private final String message;
/**
- * The location of the problem being represented.
+ * The location of the problem being represented. This field is omitted unless there is a specific
+ * location associated with the problem (such as a location where an element being renamed will be
+ * shadowed).
*/
private final Location location;
@@ -75,7 +77,9 @@ public class RefactoringProblem {
}
/**
- * The location of the problem being represented.
+ * The location of the problem being represented. This field is omitted unless there is a specific
+ * location associated with the problem (such as a location where an element being renamed will be
+ * shadowed).
*/
public Location getLocation() {
return location;
@@ -99,7 +103,9 @@ public class RefactoringProblem {
JsonObject jsonObject = new JsonObject();
jsonObject.addProperty("severity", severity);
jsonObject.addProperty("message", message);
- jsonObject.add("location", location.toJson());
+ if (location != null) {
+ jsonObject.add("location", location.toJson());
+ }
return jsonObject;
}
« no previous file with comments | « no previous file | pkg/analysis_server/doc/api.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698