File:  [Qemu by Fabrice Bellard] / qemu / qapi-schema-test.json
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs
Tue Apr 24 18:56:22 2018 UTC (3 years, 1 month ago) by root
Branches: qemu, MAIN
CVS tags: qemu1001, qemu1000, qemu0151, HEAD
qemu 0.15.1

    1: # *-*- Mode: Python -*-*
    2: 
    3: # for testing enums
    4: { 'enum': 'EnumOne',
    5:   'data': [ 'value1', 'value2', 'value3' ] }
    6: { 'type': 'NestedEnumsOne',
    7:   'data': { 'enum1': 'EnumOne', '*enum2': 'EnumOne', 'enum3': 'EnumOne', '*enum4': 'EnumOne' } }
    8: 
    9: # for testing nested structs
   10: { 'type': 'UserDefOne',
   11:   'data': { 'integer': 'int', 'string': 'str' } }
   12: 
   13: { 'type': 'UserDefTwo',
   14:   'data': { 'string': 'str',
   15:             'dict': { 'string': 'str',
   16:                       'dict': { 'userdef': 'UserDefOne', 'string': 'str' },
   17:                       '*dict2': { 'userdef': 'UserDefOne', 'string': 'str' } } } }
   18: 
   19: # testing commands
   20: { 'command': 'user_def_cmd', 'data': {} }
   21: { 'command': 'user_def_cmd1', 'data': {'ud1a': 'UserDefOne'} }
   22: { 'command': 'user_def_cmd2', 'data': {'ud1a': 'UserDefOne', 'ud1b': 'UserDefOne'}, 'returns': 'UserDefTwo' }

unix.superglobalmegacorp.com