(filename, ns)
| 16 | structindices = {} |
| 17 | |
| 18 | def loadfile(filename, ns): |
| 19 | with open(filename) as data_file: |
| 20 | data = json.load(data_file) |
| 21 | |
| 22 | i = 0 |
| 23 | for struct in data['structs']: |
| 24 | if(len(struct) > 0 and len(struct['struct'])): |
| 25 | structname = struct['struct'] |
| 26 | structlist[structname] = 'struct' |
| 27 | structindices[getclasswithoutnamespace(structname)] = i |
| 28 | i += 1 |
| 29 | |
| 30 | for typedef in data['typedefs']: |
| 31 | if(len(typedef) > 0 and len(typedef['typedef'])): |
| 32 | typedeflist[typedef['typedef']] = typedef['type'] |
| 33 | for enum in data['enums']: |
| 34 | enumname = enum['enumname'] |
| 35 | namespace = getnamespace(enumname) |
| 36 | if(len(enum) > 0 and len(enum['enumname'])): |
| 37 | enumlist[enum['enumname'].replace('::','_')] = enum['enumname'] |
| 38 | return data |
| 39 | |
| 40 | |
| 41 | def paramshavelength(params, paramname): |
nothing calls this directly
no test coverage detected