• M
    qapi2texi: Generate documentation for variant members · 5169cd87
    Markus Armbruster 提交于
    A flat union's branch brings in the members of another type.  Generate
    a suitable reference to that type.
    
    Example change (qemu-qmp-ref.txt):
    
      -- Flat Union: QCryptoBlockOpenOptions
    
          The options that are available for all encryption formats when
          opening an existing volume
    
          Members:
          The members of 'QCryptoBlockOptionsBase'
    +     The members of 'QCryptoBlockOptionsQCow' when 'format' is "qcow"
    +     The members of 'QCryptoBlockOptionsLUKS' when 'format' is "luks"
    
          Since: 2.6
    
    A simple union's branch adds a member 'data' of some other type.
    Generate documentation for that member.
    
    Example change (qemu-qmp-ref.txt):
    
      -- Simple Union: SocketAddress
    
          Captures the address of a socket, which could also be a named file
          descriptor
    
          Members:
          'type'
    	   Not documented
    +     'data: InetSocketAddress' when 'type' is "inet"
    +     'data: UnixSocketAddress' when 'type' is "unix"
    +     'data: VsockSocketAddress' when 'type' is "vsock"
    +     'data: String' when 'type' is "fd"
    
          Since: 1.3
    Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
    Reviewed-by: NEric Blake <eblake@redhat.com>
    Message-Id: <1489582656-31133-28-git-send-email-armbru@redhat.com>
    5169cd87
qapi2texi.py 8.6 KB