Acked-by: Christophe Fergeau <cferg...@redhat.com>

On Wed, Aug 17, 2016 at 06:58:47PM +0300, Visarion Alexandru wrote:
> From: Visarion Alexandru <viorel.visar...@gmail.com>
> 
> Abstract class which represents a listen child node
> of the graphics device.
> ---
>  libvirt-gconfig/Makefile.am                        |  2 +
>  .../libvirt-gconfig-domain-graphics-listen.c       | 49 ++++++++++++++++
>  .../libvirt-gconfig-domain-graphics-listen.h       | 65 
> ++++++++++++++++++++++
>  libvirt-gconfig/libvirt-gconfig.h                  |  1 +
>  libvirt-gconfig/libvirt-gconfig.sym                |  1 +
>  5 files changed, 118 insertions(+)
>  create mode 100644 libvirt-gconfig/libvirt-gconfig-domain-graphics-listen.c
>  create mode 100644 libvirt-gconfig/libvirt-gconfig-domain-graphics-listen.h
> 
> diff --git a/libvirt-gconfig/Makefile.am b/libvirt-gconfig/Makefile.am
> index 1a9a97a..09739c5 100644
> --- a/libvirt-gconfig/Makefile.am
> +++ b/libvirt-gconfig/Makefile.am
> @@ -46,6 +46,7 @@ GCONFIG_HEADER_FILES = \
>                       libvirt-gconfig-domain-filesys.h \
>                       libvirt-gconfig-domain-graphics.h \
>                       libvirt-gconfig-domain-graphics-desktop.h \
> +                     libvirt-gconfig-domain-graphics-listen.h\
>                       libvirt-gconfig-domain-graphics-rdp.h \
>                       libvirt-gconfig-domain-graphics-sdl.h \
>                       libvirt-gconfig-domain-graphics-spice.h \
> @@ -139,6 +140,7 @@ GCONFIG_SOURCE_FILES = \
>                       libvirt-gconfig-domain-filesys.c \
>                       libvirt-gconfig-domain-graphics.c \
>                       libvirt-gconfig-domain-graphics-desktop.c \
> +                     libvirt-gconfig-domain-graphics-listen.c\
>                       libvirt-gconfig-domain-graphics-rdp.c \
>                       libvirt-gconfig-domain-graphics-sdl.c \
>                       libvirt-gconfig-domain-graphics-spice.c \
> diff --git a/libvirt-gconfig/libvirt-gconfig-domain-graphics-listen.c 
> b/libvirt-gconfig/libvirt-gconfig-domain-graphics-listen.c
> new file mode 100644
> index 0000000..095abe7
> --- /dev/null
> +++ b/libvirt-gconfig/libvirt-gconfig-domain-graphics-listen.c
> @@ -0,0 +1,49 @@
> +/*
> + * libvirt-gconfig-domain-graphics-listen.c: libvirt domain graphics listen 
> base class
> + *
> + * Copyright (C) 2016 Red Hat, Inc.
> + * Copyright (C) 2016 Visarion Alexandru <viorel.visar...@gmail.com>
> + *
> + * This library is free software; you can redistribute it and/or
> + * modify it under the terms of the GNU Lesser General Public
> + * License as published by the Free Software Foundation; either
> + * version 2.1 of the License, or (at your option) any later version.
> + *
> + * This library is distributed in the hope that it will be useful,
> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
> + * Lesser General Public License for more details.
> + *
> + * You should have received a copy of the GNU Lesser General Public
> + * License along with this library. If not, see
> + * <http://www.gnu.org/licenses/>.
> + *
> + * Author: Visarion Alexandru <viorel.visar...@gmail.com>
> + */
> +
> +#include <config.h>
> +
> +#include "libvirt-gconfig/libvirt-gconfig.h"
> +#include "libvirt-gconfig/libvirt-gconfig-private.h"
> +
> +#define GVIR_CONFIG_DOMAIN_GRAPHICS_LISTEN_GET_PRIVATE(obj)                  
>        \
> +        (G_TYPE_INSTANCE_GET_PRIVATE((obj), 
> GVIR_CONFIG_TYPE_DOMAIN_GRAPHICS_LISTEN, 
> GVirConfigDomainGraphicsListenPrivate))
> +
> +struct _GVirConfigDomainGraphicsListenPrivate
> +{
> +    gboolean unused;
> +};
> +
> +G_DEFINE_ABSTRACT_TYPE(GVirConfigDomainGraphicsListen, 
> gvir_config_domain_graphics_listen, GVIR_CONFIG_TYPE_OBJECT);
> +
> +
> +static void 
> gvir_config_domain_graphics_listen_class_init(GVirConfigDomainGraphicsListenClass
>  *klass)
> +{
> +    g_type_class_add_private(klass, 
> sizeof(GVirConfigDomainGraphicsListenPrivate));
> +}
> +
> +
> +static void 
> gvir_config_domain_graphics_listen_init(GVirConfigDomainGraphicsListen 
> *listen)
> +{
> +    listen->priv = GVIR_CONFIG_DOMAIN_GRAPHICS_LISTEN_GET_PRIVATE(listen);
> +}
> diff --git a/libvirt-gconfig/libvirt-gconfig-domain-graphics-listen.h 
> b/libvirt-gconfig/libvirt-gconfig-domain-graphics-listen.h
> new file mode 100644
> index 0000000..6f93d27
> --- /dev/null
> +++ b/libvirt-gconfig/libvirt-gconfig-domain-graphics-listen.h
> @@ -0,0 +1,65 @@
> +/*
> + * libvirt-gconfig-domain-graphics-listen.h: libvirt domain graphics listen 
> base class
> + *
> + * Copyright (C) 2016 Red Hat, Inc.
> + * Copyright (C) 2016 Visarion Alexandru <viorel.visar...@gmail.com>
> + *
> + * This library is free software; you can redistribute it and/or
> + * modify it under the terms of the GNU Lesser General Public
> + * License as published by the Free Software Foundation; either
> + * version 2.1 of the License, or (at your option) any later version.
> + *
> + * This library is distributed in the hope that it will be useful,
> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
> + * Lesser General Public License for more details.
> + *
> + * You should have received a copy of the GNU Lesser General Public
> + * License along with this library. If not, see
> + * <http://www.gnu.org/licenses/>.
> + *
> + * Author: Visarion Alexandru <viorel.visar...@gmail.com>
> + */
> +
> +#if !defined(__LIBVIRT_GCONFIG_H__) && !defined(LIBVIRT_GCONFIG_BUILD)
> +#error "Only <libvirt-gconfig/libvirt-gconfig.h> can be included directly."
> +#endif
> +
> +#ifndef __LIBVIRT_GCONFIG_DOMAIN_GRAPHICS_LISTEN_H__
> +#define __LIBVIRT_GCONFIG_DOMAIN_GRAPHICS_LISTEN_H__
> +
> +G_BEGIN_DECLS
> +
> +#define GVIR_CONFIG_TYPE_DOMAIN_GRAPHICS_LISTEN            
> (gvir_config_domain_graphics_listen_get_type ())
> +#define GVIR_CONFIG_DOMAIN_GRAPHICS_LISTEN(obj)            
> (G_TYPE_CHECK_INSTANCE_CAST ((obj), GVIR_CONFIG_TYPE_DOMAIN_GRAPHICS_LISTEN, 
> GVirConfigDomainGraphicsListen))
> +#define GVIR_CONFIG_DOMAIN_GRAPHICS_LISTEN_CLASS(klass)    
> (G_TYPE_CHECK_CLASS_CAST ((klass), GVIR_CONFIG_TYPE_DOMAIN_GRAPHICS_LISTEN, 
> GVirConfigDomainGraphicsListenClass))
> +#define GVIR_CONFIG_IS_DOMAIN_GRAPHICS_LISTEN(obj)         
> (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GVIR_CONFIG_TYPE_DOMAIN_GRAPHICS_LISTEN))
> +#define GVIR_CONFIG_IS_DOMAIN_GRAPHICS_LISTEN_CLASS(klass) 
> (G_TYPE_CHECK_CLASS_TYPE ((klass), GVIR_CONFIG_TYPE_DOMAIN_GRAPHICS_LISTEN))
> +#define GVIR_CONFIG_DOMAIN_GRAPHICS_LISTEN_GET_CLASS(obj)  
> (G_TYPE_INSTANCE_GET_CLASS ((obj), GVIR_CONFIG_TYPE_DOMAIN_GRAPHICS_LISTEN, 
> GVirConfigDomainGraphicsListenClass))
> +
> +typedef struct _GVirConfigDomainGraphicsListen 
> GVirConfigDomainGraphicsListen;
> +typedef struct _GVirConfigDomainGraphicsListenPrivate 
> GVirConfigDomainGraphicsListenPrivate;
> +typedef struct _GVirConfigDomainGraphicsListenClass 
> GVirConfigDomainGraphicsListenClass;
> +
> +struct _GVirConfigDomainGraphicsListen
> +{
> +    GVirConfigObject parent;
> +
> +    GVirConfigDomainGraphicsListenPrivate *priv;
> +
> +    /* Do not add fields to this struct */
> +};
> +
> +struct _GVirConfigDomainGraphicsListenClass
> +{
> +    GVirConfigObjectClass parent_class;
> +
> +    gpointer padding[20];
> +};
> +
> +
> +GType gvir_config_domain_graphics_listen_get_type(void);
> +
> +G_END_DECLS
> +
> +#endif /* __LIBVIRT_GCONFIG_DOMAIN_GRAPHICS_LISTEN_H__ */
> diff --git a/libvirt-gconfig/libvirt-gconfig.h 
> b/libvirt-gconfig/libvirt-gconfig.h
> index 6462154..496986e 100644
> --- a/libvirt-gconfig/libvirt-gconfig.h
> +++ b/libvirt-gconfig/libvirt-gconfig.h
> @@ -63,6 +63,7 @@
>  #include <libvirt-gconfig/libvirt-gconfig-domain-filesys.h>
>  #include <libvirt-gconfig/libvirt-gconfig-domain-graphics.h>
>  #include <libvirt-gconfig/libvirt-gconfig-domain-graphics-desktop.h>
> +#include <libvirt-gconfig/libvirt-gconfig-domain-graphics-listen.h>
>  #include <libvirt-gconfig/libvirt-gconfig-domain-graphics-rdp.h>
>  #include <libvirt-gconfig/libvirt-gconfig-domain-graphics-sdl.h>
>  #include <libvirt-gconfig/libvirt-gconfig-domain-graphics-spice.h>
> diff --git a/libvirt-gconfig/libvirt-gconfig.sym 
> b/libvirt-gconfig/libvirt-gconfig.sym
> index 4ef4bf7..32d2c7b 100644
> --- a/libvirt-gconfig/libvirt-gconfig.sym
> +++ b/libvirt-gconfig/libvirt-gconfig.sym
> @@ -741,6 +741,7 @@ global:
>       gvir_config_domain_address_pci_get_multifunction;
>       gvir_config_domain_address_pci_get_slot;
>  
> +     gvir_config_domain_graphics_listen_get_type;
>       gvir_config_domain_graphics_spice_set_gl;
>  
>       gvir_config_domain_hostdev_get_boot_order;
> -- 
> 2.7.4
> 
> --
> libvir-list mailing list
> libvir-list@redhat.com
> https://www.redhat.com/mailman/listinfo/libvir-list

Attachment: signature.asc
Description: PGP signature

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

Reply via email to