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

Unified Diff: runtime/include/dart_tools_api.h

Issue 2059883003: DevFS initial implementation (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 6 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 | runtime/lib/vmservice.cc » ('j') | runtime/lib/vmservice_patch.dart » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/include/dart_tools_api.h
diff --git a/runtime/include/dart_tools_api.h b/runtime/include/dart_tools_api.h
index 961c444d702bf9f75bc00c9507106a61f0efc70c..62d9dbc1664715f42618e89e063cc69051fc1dd3 100644
--- a/runtime/include/dart_tools_api.h
+++ b/runtime/include/dart_tools_api.h
@@ -897,6 +897,44 @@ DART_EXPORT Dart_Handle Dart_ServiceSendDataEvent(const char* stream_id,
intptr_t bytes_length);
/*
+ * =====
+ * DevFS
+ * =====
+ */
+
+/**
+ * Determines if a uri is a DevFS uri.
+ *
+ * \param uri The uri to test. This parameter is a string.
+ *
+ * \return true if uri is a DevFS uri and false otherwise.
+ */
+DART_EXPORT bool Dart_IsDevFSUri(Dart_Handle uri);
turnidge 2016/06/10 18:45:34 Consider dropping the embedding api changes until
+
+
+/**
+ * Attempts to read the DevFS file at uri.
+ *
+ * \param uri The uri to read. This parameter is a string.
+ *
+ * \return A typed data array of Dart_TypedData_kUint8 containing the contents
+ * of the file. Otherwise, returns an error handle.
+ */
+DART_EXPORT Dart_Handle Dart_DevFSReadFile(Dart_Handle uri);
+
+
+/**
+ * Attempts to read the DevFS file at uri.
+ *
+ * \param uri The uri to read. This parameter is a string.
+ *
+ * \return A string containing the contents of the file. Otherwise,
+ * returns an error handle.
+ */
+DART_EXPORT Dart_Handle Dart_DevFSReadFileAsUTF8String(Dart_Handle uri);
+
+
+/*
* ========
* Timeline
* ========
« no previous file with comments | « no previous file | runtime/lib/vmservice.cc » ('j') | runtime/lib/vmservice_patch.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698