libgdamm Reference Documentation

Main Page Namespaces Book

# Gnome::Gda::XmlStorage Class Reference
[Miscellaneous]

Base class which provides saving and loading using XML structures. More...

Inheritance diagram for Gnome::Gda::XmlStorage:

[legend]
List of all members.

## Public Member Functions

Glib::ustring | get_xml_id () const
| Fetch the xml id string of the object, it's up to the caller to free the string.
const GdaXmlStorage* | gobj () const
| Provides access to the underlying C GObject.
GdaXmlStorage* | gobj ()
| Provides access to the underlying C GObject.
bool | load_from_xml (xmlNodePtr node)
| Updates the object with data stored in the XML node.
xmlNodePtr | save_to_xml () const
| Creates a new xmlNodePtr structure and fills it with data representing the object given as argument.
virtual | ~XmlStorage ()

## Static Public Member Functions

static void | add_interface (GType gtype_implementer)

## Related Functions

(Note that these are not member functions.)
Glib::RefPtr<Gnome::Gda::XmlStorage> | wrap (GdaXmlStorage* object, bool take_copy=false)
| A Glib::wrap() method for this object.

## Detailed Description

Base class which provides saving and loading using XML structures.

Any object which implements this interface can be streamed and restored to and from an XML file.

## Constructor & Destructor Documentation

virtual Gnome::Gda::XmlStorage::~XmlStorage | ( |  | ) | `[virtual]`

## Member Function Documentation

static void Gnome::Gda::XmlStorage::add_interface | ( | GType | gtype_implementer | ) | `[static]`

Glib::ustring Gnome::Gda::XmlStorage::get_xml_id | ( |  | ) | const

Fetch the xml id string of the object, it's up to the caller to free the string.

Returns:
  The xml id.

const GdaXmlStorage* Gnome::Gda::XmlStorage::gobj | ( |  | ) | const`[inline]`

Provides access to the underlying C GObject.

Reimplemented from Glib::Interface.

Reimplemented in Gnome::Gda::DictAggregate, Gnome::Gda::DictConstraint, Gnome::Gda::DictDatabase, Gnome::Gda::DictField, Gnome::Gda::DictFunction, Gnome::Gda::DictTable, Gnome::Gda::DictType, Gnome::Gda::Query, Gnome::Gda::QueryCondition, Gnome::Gda::QueryFieldAll, Gnome::Gda::QueryFieldField, Gnome::Gda::QueryFieldFunc, Gnome::Gda::QueryFieldValue, Gnome::Gda::QueryJoin, and Gnome::Gda::QueryTarget.

GdaXmlStorage* Gnome::Gda::XmlStorage::gobj | ( |  | ) | `[inline]`

Provides access to the underlying C GObject.

Reimplemented from Glib::Interface.

Reimplemented in Gnome::Gda::DictAggregate, Gnome::Gda::DictConstraint, Gnome::Gda::DictDatabase, Gnome::Gda::DictField, Gnome::Gda::DictFunction, Gnome::Gda::DictTable, Gnome::Gda::DictType, Gnome::Gda::Query, Gnome::Gda::QueryCondition, Gnome::Gda::QueryFieldAll, Gnome::Gda::QueryFieldField, Gnome::Gda::QueryFieldFunc, Gnome::Gda::QueryFieldValue, Gnome::Gda::QueryJoin, and Gnome::Gda::QueryTarget.

bool Gnome::Gda::XmlStorage::load_from_xml | ( | xmlNodePtr | node | ) |

Updates the object with data stored in the XML node.

The object MUST already exist and be of the correct type before calling this function. This is a virtual function.

Parameters:

  | node | An XML node from an XML structure.

Returns:
  `true` if no error occurred.

xmlNodePtr Gnome::Gda::XmlStorage::save_to_xml | ( |  | ) | const

Creates a new xmlNodePtr structure and fills it with data representing the object given as argument.

Returns:
  The new XML node, or `0` if an error occurred.

## Friends And Related Function Documentation

Glib::RefPtr<Gnome::Gda::XmlStorage> wrap | ( | GdaXmlStorage * | 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:

- xmlstorage.h