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

Unified Diff: chrome/common/extensions/api/devtools/experimental_console.json

Issue 10797039: Extensions Docs Server: devtools API (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: move parsing logic into utils Created 8 years, 5 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: chrome/common/extensions/api/devtools/experimental_console.json
diff --git a/chrome/common/extensions/api/devtools/experimental_console.json b/chrome/common/extensions/api/devtools/experimental_console.json
new file mode 100644
index 0000000000000000000000000000000000000000..35ea7f0db5e9358c83ed275dfe18f944a5186ec9
--- /dev/null
+++ b/chrome/common/extensions/api/devtools/experimental_console.json
@@ -0,0 +1,99 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+[
+ {
+ "namespace": "experimental.devtools.console",
+ "nocompile": true,
+ "functions": [
+ {
+ "name": "addMessage",
+ "type": "function",
+ "description": "Adds a message to the console.",
+ "parameters": [
+ { "name": "severity", "$ref": "Severity", "description": "The severity of the message." },
+ { "name": "text", "type": "string", "description": "The text of the message." }
+ ]
+ },
+ {
+ "name": "getMessages",
+ "type": "function",
+ "description": "Retrieves console messages.",
+ "parameters": [
+ {
+ "name": "callback",
+ "type": "function",
+ "description": "A function that receives console messages when the request completes.",
+ "parameters": [
+ {
+ "name": "messages",
+ "type": "array",
+ "items": { "$ref": "ConsoleMessage" },
+ "description": "Console messages."
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "types": [
+ {
+ "id": "ConsoleMessage",
+ "type": "object",
+ "description": "A console message.",
+ "properties": {
+ "severity": {
+ "$ref": "Severity",
+ "description": "Message severity."
+ },
+ "text": {
+ "type": "string",
+ "description": "The text of the console message, as represented by the first argument to the console.log() or a similar method (no parameter substitution performed)."
+ },
+ "url": {
+ "type": "string",
+ "optional": true,
+ "description": "The URL of the script that originated the message, if available."
+ },
+ "line": {
+ "type": "number",
+ "optional": true,
+ "description": "The number of the line where the message originated, if available."
+ }
+ }
+ },
+ {
+ "id": "Severity",
+ "type": "object",
+ "properties": {
+ "Tip": {
+ "type": "string"
+ },
+ "Debug": {
+ "type": "string"
+ },
+ "Log": {
+ "type": "string"
+ },
+ "Warning": {
+ "type": "string"
+ },
+ "Error": {
+ "type": "string"
+ }
+ }
+ }
+ ],
+ "events": [
+ {
+ "name": "onMessageAdded",
+ "type": "function",
+ "description": "Fired when a new message is added to the console.",
+ "parameters": [
+ { "name": "message", "$ref": "ConsoleMessage" }
+ ]
+ }
+ ]
+ }
+]

Powered by Google App Engine
This is Rietveld 408576698