gnomemm r1550 - in libgdamm/branches/libgdamm-4-0: libgda/src tools/m4
- From: jhs svn gnome org
- To: svn-commits-list gnome org
- Subject: gnomemm r1550 - in libgdamm/branches/libgdamm-4-0: libgda/src tools/m4
- Date: Tue, 3 Jun 2008 13:26:15 +0000 (UTC)
Author: jhs
Date: Tue Jun 3 13:26:15 2008
New Revision: 1550
URL: http://svn.gnome.org/viewvc/gnomemm?rev=1550&view=rev
Log:
2008-06-03 Johannes Schmid <johannes schmid openismus com>
* libgda/src/Makefile_list_of_hg.am_fragment:
* libgda/src/config.ccg:
* libgda/src/config.hg:
* tools/m4/convert_libgdamm.m4:
Wrapped Gda::Config
Added:
libgdamm/branches/libgdamm-4-0/libgda/src/config.ccg
libgdamm/branches/libgdamm-4-0/libgda/src/config.hg
Modified:
libgdamm/branches/libgdamm-4-0/libgda/src/Makefile_list_of_hg.am_fragment
libgdamm/branches/libgdamm-4-0/tools/m4/convert_libgdamm.m4
Modified: libgdamm/branches/libgdamm-4-0/libgda/src/Makefile_list_of_hg.am_fragment
==============================================================================
--- libgdamm/branches/libgdamm-4-0/libgda/src/Makefile_list_of_hg.am_fragment (original)
+++ libgdamm/branches/libgdamm-4-0/libgda/src/Makefile_list_of_hg.am_fragment Tue Jun 3 13:26:15 2008
@@ -11,7 +11,7 @@
handlernumerical.hg handlerbin.hg handlertype.hg \
serverprovider.hg serveroperation.hg transactionstatus.hg \
set.hg row.hg column.hg holder.hg statement.hg sqlparser.hg \
- batch.hg metastore.hg metastruct.hg
+ batch.hg metastore.hg metastruct.hg config.hg
Added: libgdamm/branches/libgdamm-4-0/libgda/src/config.ccg
==============================================================================
--- (empty file)
+++ libgdamm/branches/libgdamm-4-0/libgda/src/config.ccg Tue Jun 3 13:26:15 2008
@@ -0,0 +1,64 @@
+// -*- C++ -*- // this is for the .ccg, I realize gensig puts one in
+
+/* config.cc
+ *
+ * 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 <libgdamm/config.h>
+#include <libgda/gda-config.h>
+
+namespace Gnome
+{
+
+namespace Gda
+{
+
+bool Config::dsn_needs_authentication(const Glib::ustring& dsn_name)
+{
+ return gda_config_dsn_needs_authentication(dsn_name.c_str());
+}
+
+Glib::RefPtr<DataModel> Config::list_dsn()
+{
+ return Glib::wrap(gda_config_list_dsn());
+}
+
+Glib::RefPtr<DataModel> Config::list_providers()
+{
+ return Glib::wrap(gda_config_list_providers());
+}
+
+int Config::get_nb_dsn()
+{
+ return gda_config_get_nb_dsn();
+}
+
+int Config::get_dsn_index(const Glib::ustring& dsn_name)
+{
+ return gda_config_get_dsn_index(dsn_name.c_str());
+}
+
+bool Config::can_modify_system_config()
+{
+ return gda_config_can_modify_system_config();
+}
+
+} // namespace Gda
+
+} /* namespace Gnome */
+
Added: libgdamm/branches/libgdamm-4-0/libgda/src/config.hg
==============================================================================
--- (empty file)
+++ libgdamm/branches/libgdamm-4-0/libgda/src/config.hg Tue Jun 3 13:26:15 2008
@@ -0,0 +1,63 @@
+// -*- C++ -*- // this is for the .hg, I realize gensig puts one in
+
+/* config.h
+ *
+ * Copyright 2006 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 <libgdamm/serverprovider.h>
+#include <libgdamm/datamodel.h>
+
+_DEFS(libgdamm,libgda)
+_PINCLUDE(glibmm/private/object_p.h)
+
+namespace Gnome
+{
+
+namespace Gda
+{
+
+/** Configuration â Access/Management of libgda configuration
+ *
+ * @ingroup Configuration
+ */
+class Config : public Glib::Object
+{
+ _CLASS_GOBJECT(Config, GdaConfig, GDA_CONFIG, Glib::Object, GObject)
+protected:
+ _CTOR_DEFAULT;
+public:
+ _WRAP_METHOD(static Glib::RefPtr<Config> get(), gda_config_get, refreturn)
+
+ _WRAP_METHOD_DOCS_ONLY(gda_config_dsn_needs_authentication)
+ static bool dsn_needs_authentication(const Glib::ustring& dsn_name);
+ _WRAP_METHOD_DOCS_ONLY(gda_config_list_dsn)
+ static Glib::RefPtr<DataModel> list_dsn();
+ _WRAP_METHOD_DOCS_ONLY(gda_config_list_providers)
+ static Glib::RefPtr<DataModel> list_providers();
+ _WRAP_METHOD_DOCS_ONLY(gda_config_get_nb_dsn)
+ static int get_nb_dsn();
+ _WRAP_METHOD_DOCS_ONLY(gda_config_get_dsn_index)
+ static int get_dsn_index(const Glib::ustring& dsn_name);
+ _WRAP_METHOD_DOCS_ONLY(gda_config_can_modify_system_config)
+ static bool can_modify_system_config();
+};
+
+} // namespace Gda
+} // namespace Gnome
+
Modified: libgdamm/branches/libgdamm-4-0/tools/m4/convert_libgdamm.m4
==============================================================================
--- libgdamm/branches/libgdamm-4-0/tools/m4/convert_libgdamm.m4 (original)
+++ libgdamm/branches/libgdamm-4-0/tools/m4/convert_libgdamm.m4 Tue Jun 3 13:26:15 2008
@@ -22,6 +22,7 @@
_CONVERSION(`GdaSqlParser*',`Glib::RefPtr<SqlParser>',`Glib::wrap($3)')
_CONVERSION(`GdaBatch*',`Glib::RefPtr<Batch>',`Glib::wrap($3)')
_CONVERSION(`GdaMetaStruct*',`Glib::RefPtr<MetaStruct>',`Glib::wrap($3)')
+_CONVERSION(`GdaConfig*',`Glib::RefPtr<Config>',`Glib::wrap($3)')
_CONVERSION(`const Glib::RefPtr<DataModel>&', `GdaDataModel*', __CONVERT_REFPTR_TO_P)
_CONVERSION(`const Glib::RefPtr<DataHandler>&', `GdaDataHandler*', __CONVERT_REFPTR_TO_P)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]