summaryrefslogtreecommitdiffstats
path: root/tools/json_schema_compiler/model.py
diff options
context:
space:
mode:
authorhebert.christopherj@chromium.org <hebert.christopherj@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-07-23 18:40:08 +0000
committerhebert.christopherj@chromium.org <hebert.christopherj@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-07-23 18:40:08 +0000
commitd32b8e52aa23e26ff6903c491b9fa16953a0e521 (patch)
tree7fcf81b721010e9b3158707714fb49d19ffa356a /tools/json_schema_compiler/model.py
parentadb4690d4a7c1cfd96eb2bfc4696e91dc4b8bcbd (diff)
downloadchromium_src-d32b8e52aa23e26ff6903c491b9fa16953a0e521.zip
chromium_src-d32b8e52aa23e26ff6903c491b9fa16953a0e521.tar.gz
chromium_src-d32b8e52aa23e26ff6903c491b9fa16953a0e521.tar.bz2
Extension Docs Server Version 2: Various fixes.
Callbacks no longer appear when they shouldn't. Types now have events. Page_capture api now has the onChange event. Step 1 appears in the table of contents for the permissions API. BUG=138167 TEST= Review URL: https://chromiumcodereview.appspot.com/10800047 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@147890 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'tools/json_schema_compiler/model.py')
-rw-r--r--tools/json_schema_compiler/model.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/tools/json_schema_compiler/model.py b/tools/json_schema_compiler/model.py
index 42d38b0..5453e11 100644
--- a/tools/json_schema_compiler/model.py
+++ b/tools/json_schema_compiler/model.py
@@ -64,6 +64,7 @@ class Type(object):
- |description| the description of the type (if provided)
- |properties| a map of property unix_names to their model.Property
- |functions| a map of function names to their model.Function
+ - |events| a map of event names to their model.Event
- |from_client| indicates that instances of the Type can originate from the
users of generated code, such as top-level types and function results
- |from_json| indicates that instances of the Type can originate from the
@@ -94,6 +95,7 @@ class Type(object):
self.parent = parent
self.instance_of = json.get('isInstanceOf', None)
_AddFunctions(self, json)
+ _AddEvents(self, json)
_AddProperties(self, json, from_json=True, from_client=True)
additional_properties_key = 'additionalProperties'