Re: [libvirt-glib 26/37] Add gvir_config_interface_set_source

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

 



On Fri, Nov 11, 2011 at 08:08:37PM +0100, Marc-André Lureau wrote:
> On Thu, Nov 10, 2011 at 9:33 PM, Christophe Fergeau <cfergeau@xxxxxxxxxx> wrote:
> > The way it's done is just a band-aid though. The need for this
> > 'type' member in GVirConfigInterface and GVirConfigDeviceDisk is
> > a clear indication that they should be separate class.
> 
> You mean there should be a seperate class for source type?

The interface xml node is 
<interface type="xxx"> .... </interface>

What I meant in the commit message is that instead of trying to handle all
possible interface types in a single GVirConfigInterface, we should have
one class per interface type (ie <interface type="xxx"> would be
represented by one class, and <interface type="yyy"> would be a different
class). Since the value of the attribute is not free-form, this is
workable.
And this is what the "Add GVirConfigInterfaceNetwork" patch does. I haven't
done it (yet?) for the GVirConfigDeviceDisk class since for now it was no
big deal not to have the specialized classes.

Christophe

Attachment: pgpiYYkABcQUf.pgp
Description: PGP signature

--
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]