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

Unified Diff: editor/tools/plugins/com.google.dart.server/src/com/google/dart/server/internal/remote/FileReadMode.java

Issue 857283003: Addition of the new flag "file-read-mode" into the analysis server to fix the offset bug with Intel… (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 11 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.server/src/com/google/dart/server/internal/remote/FileReadMode.java
diff --git a/editor/tools/plugins/com.google.dart.server/src/com/google/dart/server/internal/remote/RequestSink.java b/editor/tools/plugins/com.google.dart.server/src/com/google/dart/server/internal/remote/FileReadMode.java
similarity index 54%
copy from editor/tools/plugins/com.google.dart.server/src/com/google/dart/server/internal/remote/RequestSink.java
copy to editor/tools/plugins/com.google.dart.server/src/com/google/dart/server/internal/remote/FileReadMode.java
index c4af60a3f509cd1ca41eaaab69246edb2cb9a007..6845bb5dc96d191322c17b847cba3b95477011c9 100644
--- a/editor/tools/plugins/com.google.dart.server/src/com/google/dart/server/internal/remote/RequestSink.java
+++ b/editor/tools/plugins/com.google.dart.server/src/com/google/dart/server/internal/remote/FileReadMode.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2014, the Dart project authors.
+ * Copyright (c) 2015, the Dart project authors.
*
* Licensed under the Eclipse Public License v1.0 (the "License"); you may not use this file except
* in compliance with the License. You may obtain a copy of the License at
@@ -13,23 +13,22 @@
*/
package com.google.dart.server.internal.remote;
-import com.google.gson.JsonObject;
-
/**
- * A destination for remote server requests.
+ * An enumeration of the services provided by the analysis domain. An enumeration of the ways files
+ * can be read from disk. Some clients normalize end of line characters which would make the file
+ * offset and range information incorrect.
*
* @coverage dart.server.remote
*/
-public interface RequestSink {
+public enum FileReadMode {
/**
- * Put request into the sink.
- *
- * @param request the request to put, not {@code null}.
+ * File contents are read as-is, no file changes occur.
*/
- void add(JsonObject request);
+ AS_IS,
/**
- * Close the communication channel.
+ * File contents normalize the end of line characters to the single character new line '\n'.
+ * public static final String INVALIDATE = "INVALIDATE";
*/
- void close();
+ NORMALIZE_EOL;
}

Powered by Google App Engine
This is Rietveld 408576698