Home | History | Annotate | Download | only in json_to_struct

Lines Matching refs:schema

6 # Format for the JSON schema file:
12 # "schema": [ // Fields of the generated structure.
70 // GENERATED FROM THE SCHEMA DEFINITION AND DESCRIPTION IN
83 def _GenerateH(basepath, fileroot, head, namespace, schema, description):
85 by the schema.
93 schema: A dict containing the schema. See comment at the top of this file.
110 for header in schema.get('headers', []):
119 schema['type_name'], schema['schema']))
127 f.write('extern const %s %s;\n' % (schema['type_name'], element_name))
136 def _GenerateCC(basepath, fileroot, head, namespace, schema, description):
146 schema: A dict containing the schema. See comment at the top of this file.
161 f.write(element_generator.GenerateElements(schema['type_name'],
162 schema['schema'], description))
179 usage='usage: %prog [option] -s schema description')
186 parser.add_option('-s', '--schema', help='path to the schema file, '
190 if not opts.schema:
191 parser.error('You must specify a --schema.')
206 schema = _Load(opts.schema)
209 head = HEAD % (datetime.now().year, opts.schema, description_filename)
210 _GenerateH(basepath, output_root, head, opts.namespace, schema, description)
211 _GenerateCC(basepath, output_root, head, opts.namespace, schema, description)