
/*

  KLayout Layout Viewer
  Copyright (C) 2006-2016 Matthias Koefferlein

  This program is free software; you can redistribute it and/or modify
  it under the terms of the GNU General Public License as published by
  the Free Software Foundation; either version 2 of the License, or
  (at your option) any later version.

  This program 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 General Public License for more details.

  You should have received a copy of the GNU General Public License
  along with this program; if not, write to the Free Software
  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA

*/

/**
*  @file gsiDeclQChildEvent.cc 
*
*  DO NOT EDIT THIS FILE. 
*  This file has been created automatically
*/

#include "gsiQtCore.h"
#include "gsiDeclQtTypeTraits.h"
#include "gsiDeclQChildEvent_Enums.h"
#include <memory>

// -----------------------------------------------------------------------
// class QChildEvent

// bool QChildEvent::added()


static void _init_f_added_c0 (qt_gsi::GenericMethod *decl)
{
  decl->set_return<bool > ();
}

static void _call_f_added_c0 (const qt_gsi::GenericMethod *decl, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret) 
{
  ret.write<bool > ((bool)((QChildEvent *)cls)->added ());
}

static qt_gsi::GenericMethod *_create_f_added_c0 ()
{
  return new qt_gsi::GenericMethod ("added", "@brief Method bool QChildEvent::added()\n", true, &_init_f_added_c0, &_call_f_added_c0);
}

// QObject *QChildEvent::child()


static void _init_f_child_c0 (qt_gsi::GenericMethod *decl)
{
  decl->set_return<QObject * > ();
}

static void _call_f_child_c0 (const qt_gsi::GenericMethod *decl, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret) 
{
  ret.write<QObject * > ((QObject *)((QChildEvent *)cls)->child ());
}

static qt_gsi::GenericMethod *_create_f_child_c0 ()
{
  return new qt_gsi::GenericMethod ("child", "@brief Method QObject *QChildEvent::child()\n", true, &_init_f_child_c0, &_call_f_child_c0);
}

// bool QChildEvent::polished()


static void _init_f_polished_c0 (qt_gsi::GenericMethod *decl)
{
  decl->set_return<bool > ();
}

static void _call_f_polished_c0 (const qt_gsi::GenericMethod *decl, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret) 
{
  ret.write<bool > ((bool)((QChildEvent *)cls)->polished ());
}

static qt_gsi::GenericMethod *_create_f_polished_c0 ()
{
  return new qt_gsi::GenericMethod ("polished", "@brief Method bool QChildEvent::polished()\n", true, &_init_f_polished_c0, &_call_f_polished_c0);
}

// bool QChildEvent::removed()


static void _init_f_removed_c0 (qt_gsi::GenericMethod *decl)
{
  decl->set_return<bool > ();
}

static void _call_f_removed_c0 (const qt_gsi::GenericMethod *decl, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret) 
{
  ret.write<bool > ((bool)((QChildEvent *)cls)->removed ());
}

static qt_gsi::GenericMethod *_create_f_removed_c0 ()
{
  return new qt_gsi::GenericMethod ("removed", "@brief Method bool QChildEvent::removed()\n", true, &_init_f_removed_c0, &_call_f_removed_c0);
}

namespace gsi
{
extern gsi::Class<QEvent> decl_QEvent;

gsi::Class<QChildEvent> decl_QChildEvent (decl_QEvent, "QChildEvent_Native",
  gsi::Methods(_create_f_added_c0 ()) +
  gsi::Methods(_create_f_child_c0 ()) +
  gsi::Methods(_create_f_polished_c0 ()) +
  gsi::Methods(_create_f_removed_c0 ()),
  "@hide\n@alias QChildEvent");
}


class QChildEvent_Adaptor : public QChildEvent, public qt_gsi::QtObjectBase
{
public:

  virtual ~QChildEvent_Adaptor();

  //  [adaptor ctor] QChildEvent::QChildEvent(QEvent::Type type, QObject *child)
  QChildEvent_Adaptor(QEvent::Type type, QObject *child) : QChildEvent(type, child)
  {
    qt_gsi::QtObjectBase::init (this);
  }

  
};

QChildEvent_Adaptor::~QChildEvent_Adaptor() { }

//  Constructor QChildEvent::QChildEvent(QEvent::Type type, QObject *child) (adaptor class)

static void _init_ctor_QChildEvent_Adaptor_2759 (qt_gsi::GenericStaticMethod *decl)
{
  static gsi::ArgSpecBase argspec_0 ("type");
  decl->add_arg<const qt_gsi::Converter<QEvent::Type>::target_type & > (argspec_0);
  static gsi::ArgSpecBase argspec_1 ("child");
  decl->add_arg<QObject * > (argspec_1);
  decl->set_return_new<QChildEvent_Adaptor *> ();
}

static void _call_ctor_QChildEvent_Adaptor_2759 (const qt_gsi::GenericStaticMethod *decl, gsi::SerialArgs &args, gsi::SerialArgs &ret) 
{
  const qt_gsi::Converter<QEvent::Type>::target_type & arg1 = args.read<const qt_gsi::Converter<QEvent::Type>::target_type & > ();
  QObject *arg2 = args.read<QObject * > ();
  ret.write<QChildEvent_Adaptor *> (new QChildEvent_Adaptor (qt_gsi::QtToCppAdaptor<QEvent::Type>(arg1).cref(), arg2));
}

static qt_gsi::GenericStaticMethod *_create_ctor_QChildEvent_Adaptor_2759 ()
{
  return new qt_gsi::GenericStaticMethod ("new", "@brief Constructor QChildEvent::QChildEvent(QEvent::Type type, QObject *child)\nThis method creates an object of class QChildEvent.", &_init_ctor_QChildEvent_Adaptor_2759, &_call_ctor_QChildEvent_Adaptor_2759);
}

namespace gsi
{

extern gsi::Class<QChildEvent> decl_QChildEvent;

gsi::Class<QChildEvent_Adaptor> decl_QChildEvent_Adaptor (decl_QChildEvent, "QChildEvent",
  gsi::Methods(_create_ctor_QChildEvent_Adaptor_2759 ()),
  "@qt\n@brief Binding of QChildEvent");

}

