// -*- c++ -*-
// Generated by gtkmmproc -- DO NOT MODIFY!
#ifndef _LIBGDAMM_ERROR_H
#define _LIBGDAMM_ERROR_H

#include <glibmm.h>

/* $Id: error.hg,v 1.6 2004/04/04 20:40:00 murrayc Exp $ */
// -*- C++ -*- // this is for the .hg, I realize gensig puts one in

/* error.h
 *
 * Copyright 2003 libgdamm Development Team
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Library General Public
 * License as published by the Free Software Foundation; either
 * version 2 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
 * Library General Public License for more details.
 *
 * You should have received a copy of the GNU Library General Public
 * License along with this library; if not, write to the Free
 * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 */

#include <glibmm/object.h>
#include <libgda/gda-error.h>


#ifndef DOXYGEN_SHOULD_SKIP_THIS
typedef struct _GdaError GdaError;
typedef struct _GdaErrorClass GdaErrorClass;
#endif /* DOXYGEN_SHOULD_SKIP_THIS */


namespace Gnome
{

namespace Gda
{ class Error_Class; } // namespace Gda

} // namespace Gnome
namespace Gnome
{

namespace Gda
{


class Error : public Glib::Object
{
  
#ifndef DOXYGEN_SHOULD_SKIP_THIS

public:
  typedef Error CppObjectType;
  typedef Error_Class CppClassType;
  typedef GdaError BaseObjectType;
  typedef GdaErrorClass BaseClassType;

private:  friend class Error_Class;
  static CppClassType error_class_;

private:
  // noncopyable
  Error(const Error&);
  Error& operator=(const Error&);

protected:
  explicit Error(const Glib::ConstructParams& construct_params);
  explicit Error(GdaError* castitem);

#endif /* DOXYGEN_SHOULD_SKIP_THIS */

public:
  virtual ~Error();

#ifndef DOXYGEN_SHOULD_SKIP_THIS
  static GType get_type()      G_GNUC_CONST;
  static GType get_base_type() G_GNUC_CONST;
#endif

  ///Provides access to the underlying C GObject.
  GdaError*       gobj()       { return reinterpret_cast<GdaError*>(gobject_); }

  ///Provides access to the underlying C GObject.
  const GdaError* gobj() const { return reinterpret_cast<GdaError*>(gobject_); }

  ///Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs.
  GdaError* gobj_copy();

private:

  
protected:

 Error();

public:
  
  static Glib::RefPtr<Error> create();


  Glib::ustring get_description() const;
  
  void set_description(const Glib::ustring& description);
  
  glong get_number() const;
  
  void set_number(glong number);
  
  Glib::ustring get_source() const;
  
  void set_source(const Glib::ustring& source);
  
  Glib::ustring get_sqlstate() const;
  
  void set_sqlstate(const Glib::ustring& sqlstate);


public:

public:
  //C++ methods used to invoke GTK+ virtual functions:

protected:
  //GTK+ Virtual Functions (override these to change behaviour):

  //Default Signal Handlers::


};

} // namespace Gda
} // namespace Gnome


namespace Glib
{
  /** @relates Gnome::Gda::Error
   * @param object The C instance
   * @param take_copy False if the result should take ownership of the C instance. True if it should take a new copy or ref.
   * @result A C++ instance that wraps this C instance.
   */
  Glib::RefPtr<Gnome::Gda::Error> wrap(GdaError* object, bool take_copy = false);
}


#endif /* _LIBGDAMM_ERROR_H */

