| Index: tools/json_schema_compiler/model.py
|
| diff --git a/tools/json_schema_compiler/model.py b/tools/json_schema_compiler/model.py
|
| index 53b3aee124c0d60736afabd9dd0bde3656c76759..9a5c55f07b54f56797e01cc763ef6715a0450a70 100644
|
| --- a/tools/json_schema_compiler/model.py
|
| +++ b/tools/json_schema_compiler/model.py
|
| @@ -16,12 +16,8 @@ class Model(object):
|
| self.namespaces = {}
|
|
|
| def AddNamespace(self, json, source_file):
|
| - """Add a namespace's json to the model if it doesn't have "nocompile"
|
| - property set to true. Returns the new namespace or None if a namespace
|
| - wasn't added.
|
| + """Add a namespace's json to the model and returns the namespace.
|
| """
|
| - if json.get('nocompile', False):
|
| - return None
|
| namespace = Namespace(json, source_file)
|
| self.namespaces[namespace.name] = namespace
|
| return namespace
|
| @@ -54,8 +50,7 @@ class Namespace(object):
|
| type_ = Type(self, type_json['id'], type_json)
|
| self.types[type_.name] = type_
|
| for function_json in json.get('functions', []):
|
| - if not function_json.get('nocompile', False):
|
| - self.functions[function_json['name']] = Function(self, function_json)
|
| + self.functions[function_json['name']] = Function(self, function_json)
|
|
|
| class Type(object):
|
| """A Type defined in the json.
|
| @@ -94,8 +89,7 @@ class Type(object):
|
| self.functions = {}
|
| self.parent = parent
|
| for function_json in json.get('functions', []):
|
| - if not function_json.get('nocompile', False):
|
| - self.functions[function_json['name']] = Function(self, function_json)
|
| + self.functions[function_json['name']] = Function(self, function_json)
|
| props = []
|
| for prop_name, prop_json in json.get('properties', {}).items():
|
| # TODO(calamity): support functions (callbacks) as properties. The model
|
|
|