Gnome::Gda::Config Class Reference

Configuration — Access/Management of libgda configuration. More...

Inherits Glib::Object.

Collaboration diagram for Gnome::Gda::Config:
Collaboration graph
[legend]

List of all members.

Public Member Functions

virtual ~Config ()
GdaConfig* gobj ()
 Provides access to the underlying C GObject.
const GdaConfig* gobj () const
 Provides access to the underlying C GObject.
GdaConfig* gobj_copy ()
 Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs.
Glib::SignalProxy1< void,
GdaDsnInfo* > 
signal_dsn_added ()
Glib::SignalProxy1< void,
GdaDsnInfo* > 
signal_dsn_changed ()
Glib::SignalProxy1< void,
GdaDsnInfo* > 
signal_dsn_removed ()
Glib::SignalProxy1< void,
GdaDsnInfo* > 
signal_dsn_to_be_removed ()
Glib::PropertyProxy
< Glib::ustring
property_system_filename ()
 File to use for system-wide DSN list.
Glib::PropertyProxy_ReadOnly
< Glib::ustring
property_system_filename () const
 File to use for system-wide DSN list.
Glib::PropertyProxy
< Glib::ustring
property_user_filename ()
 File to use for per-user DSN list.
Glib::PropertyProxy_ReadOnly
< Glib::ustring
property_user_filename () const
 File to use for per-user DSN list.

Static Public Member Functions

static Glib::RefPtr< Configget ()
 Get a pointer to the global GdaConfig object.
static GdaDsnInfo* get_dsn_info (const Glib::ustring& dsn_name)
 Get information about the DSN named dsn_name.
static bool dsn_needs_authentication (const Glib::ustring& dsn_name)
static Glib::RefPtr< DataModellist_dsn ()
 Get a Gda::DataModel representing all the configured DSN, and keeping itself up to date with the changes in the declared DSN.
static Glib::RefPtr< DataModellist_providers ()
 Get a Gda::DataModel representing all the installed database providers.
static int get_nb_dsn ()
 Get the number of defined DSN.
static bool can_modify_system_config ()
 Tells if the global (system) configuration can be modified (considering system permissions and settings).

Protected Member Functions

 Config ()

Related Functions

(Note that these are not member functions.)



Glib::RefPtr< Gnome::Gda::Configwrap (GdaConfig* object, bool take_copy=false)
 A Glib::wrap() method for this object.

Detailed Description

Configuration — Access/Management of libgda configuration.


Constructor & Destructor Documentation

virtual Gnome::Gda::Config::~Config (  )  [virtual]
Gnome::Gda::Config::Config (  )  [protected]

Member Function Documentation

static bool Gnome::Gda::Config::can_modify_system_config (  )  [static]

Tells if the global (system) configuration can be modified (considering system permissions and settings).

Returns:
true if system-wide configuration can be modified.
static bool Gnome::Gda::Config::dsn_needs_authentication ( const Glib::ustring dsn_name  )  [static]
static Glib::RefPtr<Config> Gnome::Gda::Config::get (  )  [static]

Get a pointer to the global GdaConfig object.

Returns:
A non 0 pointer to a Gda::Config.
static GdaDsnInfo* Gnome::Gda::Config::get_dsn_info ( const Glib::ustring dsn_name  )  [static]

Get information about the DSN named dsn_name.

dsn_name's format is "[&lt;username&gt;[:&lt;password&gt;]@]&lt;DSN&gt;" (if <username> and optionaly <password> are provided, they are ignored). Also see the gda_dsn_split() utility function.

Parameters:
dsn_name The name of the DSN to look for.
Returns:
A a pointer to read-only Gda::DsnInfo structure, or 0 if not found.
static int Gnome::Gda::Config::get_nb_dsn (  )  [static]

Get the number of defined DSN.

Return: the number of defined DSN

const GdaConfig* Gnome::Gda::Config::gobj (  )  const [inline]

Provides access to the underlying C GObject.

Reimplemented from Glib::ObjectBase.

GdaConfig* Gnome::Gda::Config::gobj (  )  [inline]

Provides access to the underlying C GObject.

Reimplemented from Glib::ObjectBase.

GdaConfig* Gnome::Gda::Config::gobj_copy (  ) 

Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs.

static Glib::RefPtr<DataModel> Gnome::Gda::Config::list_dsn (  )  [static]

Get a Gda::DataModel representing all the configured DSN, and keeping itself up to date with the changes in the declared DSN.

The returned data model is composed of the following columns: <itemizedlist> <listitem>DSN name</listitem> <listitem>Provider name</listitem> <listitem>Description</listitem> <listitem>Connection string</listitem> <listitem>Username if it exists</listitem> </itemizedlist>

Returns:
A new Gda::DataModel.
static Glib::RefPtr<DataModel> Gnome::Gda::Config::list_providers (  )  [static]

Get a Gda::DataModel representing all the installed database providers.

The returned data model is composed of the following columns: <itemizedlist> <listitem>Provider name</listitem> <listitem>Description</listitem> <listitem>DSN parameters</listitem> <listitem>Authentication parameters</listitem> <listitem>File name of the plugin</listitem> </itemizedlist>

Returns:
A new Gda::DataModel.
Glib::PropertyProxy_ReadOnly<Glib::ustring> Gnome::Gda::Config::property_system_filename (  )  const

File to use for system-wide DSN list.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.
Glib::PropertyProxy<Glib::ustring> Gnome::Gda::Config::property_system_filename (  ) 

File to use for system-wide DSN list.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.
Glib::PropertyProxy_ReadOnly<Glib::ustring> Gnome::Gda::Config::property_user_filename (  )  const

File to use for per-user DSN list.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.
Glib::PropertyProxy<Glib::ustring> Gnome::Gda::Config::property_user_filename (  ) 

File to use for per-user DSN list.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.
Glib::SignalProxy1< void,GdaDsnInfo* > Gnome::Gda::Config::signal_dsn_added (  ) 
Prototype:
void on_my_dsn_added(GdaDsnInfo* info)
Glib::SignalProxy1< void,GdaDsnInfo* > Gnome::Gda::Config::signal_dsn_changed (  ) 
Prototype:
void on_my_dsn_changed(GdaDsnInfo* info)
Glib::SignalProxy1< void,GdaDsnInfo* > Gnome::Gda::Config::signal_dsn_removed (  ) 
Prototype:
void on_my_dsn_removed(GdaDsnInfo* info)
Glib::SignalProxy1< void,GdaDsnInfo* > Gnome::Gda::Config::signal_dsn_to_be_removed (  ) 
Prototype:
void on_my_dsn_to_be_removed(GdaDsnInfo* info)

Friends And Related Function Documentation

Glib::RefPtr< Gnome::Gda::Config > wrap ( GdaConfig *  object,
bool  take_copy = false 
) [related]

A Glib::wrap() method for this object.

Parameters:
object The C instance.
take_copy False if the result should take ownership of the C instance. True if it should take a new copy or ref.
Returns:
A C++ instance that wraps this C instance.

The documentation for this class was generated from the following file:

Generated on Thu Feb 25 20:18:22 2010 for libgdamm by  doxygen 1.6.1