Re: [libvirt] [PATCH] esx: Generate method mappings via macros

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2010/3/22 Daniel P. Berrange <berrange@xxxxxxxxxx>:
> On Mon, Mar 22, 2010 at 01:53:50AM +0100, Matthias Bolte wrote:
>> This is actually a consequence of the reworked required parameter
>> checking: Unify the required parameter check into a Validate function
>> instead of doing it separately im the (de)serialization part.
>>
>> The required parameter checking for the mapped methods parameter was
>> done in the (de)serialize functions before. Now it's explicitly done
>> in the mapped method itself.
>> ---
>>
>> git produces a somwhat confusing diff for esx_vi_methods.c, basically
>> the whole file is rewritten.
>
> Indeed !  The new code has alot less manual duplication of XML generation,
> so ACK
>
> Daniel
>

Thanks, pushed!

I'm currently working on a python script, that'll generate most of the
type mapping code in esx_vi_types.[ch] from definitions like this one

object VirtualMachineQuestionInfo
    String id r
    String text r
    ChoiceOption choice r
    VirtualMachineMessage message i
end

Because even with the macro based code generation, manually adding new
types is currently tedious and error prone. The generator will
simplify adding new types. I'm planning to extend it in order to
handle the method mapping as well. So this patch is a first step
towards that.

Matthias

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]