// Generated by gtkmmproc -- DO NOT MODIFY! #include #include /* This file intentionally left blank */ namespace { } // anonymous namespace namespace Glib { Gnome::Conf::Schema wrap(GConfSchema* object, bool take_copy /* = false */) { return Gnome::Conf::Schema(object, take_copy); } } // namespace Glib namespace Gnome { namespace Conf { Schema::Schema() : gobject_ (gconf_schema_new()) {} Schema::Schema(const Schema& src) : gobject_ ((src.gobject_) ? gconf_schema_copy(src.gobject_) : 0) {} Schema::Schema(GConfSchema* castitem, bool make_a_copy /* = false */) { if(!make_a_copy) { // It was given to us by a function which has already made a copy for us to keep. gobject_ = castitem; } else { // We are probably getting it via direct access to a struct, // so we can not just take it - we have to take a copy of it. if(castitem) gobject_ = gconf_schema_copy(castitem); else gobject_ = 0; } } Schema& Schema::operator=(const Schema& src) { GConfSchema *const new_gobject = (src.gobject_) ? gconf_schema_copy(src.gobject_) : 0; if(gobject_) gconf_schema_free(gobject_); gobject_ = new_gobject; return *this; } Schema::~Schema() { if(gobject_) gconf_schema_free(gobject_); } GConfSchema* Schema::gobj_copy() const { return gconf_schema_copy(gobject_); } void Schema::set_type(ValueType type) { gconf_schema_set_type(gobj(), ((GConfValueType)(type))); } void Schema::set_list_type(ValueType type) { gconf_schema_set_list_type(gobj(), ((GConfValueType)(type))); } void Schema::set_car_type(ValueType type) { gconf_schema_set_car_type(gobj(), ((GConfValueType)(type))); } void Schema::set_cdr_type(ValueType type) { gconf_schema_set_cdr_type(gobj(), ((GConfValueType)(type))); } void Schema::set_locale(const std::string& locale) { gconf_schema_set_locale(gobj(), locale.c_str()); } void Schema::set_short_desc(const Glib::ustring& desc) { gconf_schema_set_short_desc(gobj(), desc.c_str()); } void Schema::set_long_desc(const Glib::ustring& desc) { gconf_schema_set_long_desc(gobj(), desc.c_str()); } void Schema::set_owner(const Glib::ustring& owner) { gconf_schema_set_owner(gobj(), owner.c_str()); } void Schema::set_default_value(const Value& value) { gconf_schema_set_default_value(gobj(), (value).gobj()); } ValueType Schema::get_type() const { return ((ValueType)(gconf_schema_get_type(const_cast(gobj())))); } ValueType Schema::get_list_type() const { return ((ValueType)(gconf_schema_get_list_type(const_cast(gobj())))); } ValueType Schema::get_car_type() const { return ((ValueType)(gconf_schema_get_car_type(const_cast(gobj())))); } ValueType Schema::get_cdr_type() const { return ((ValueType)(gconf_schema_get_cdr_type(const_cast(gobj())))); } std::string Schema::get_locale() const { return Glib::convert_const_gchar_ptr_to_stdstring(gconf_schema_get_locale(const_cast(gobj()))); } Glib::ustring Schema::get_short_desc() const { return Glib::convert_const_gchar_ptr_to_ustring(gconf_schema_get_short_desc(const_cast(gobj()))); } Glib::ustring Schema::get_long_desc() const { return Glib::convert_const_gchar_ptr_to_ustring(gconf_schema_get_long_desc(const_cast(gobj()))); } Glib::ustring Schema::get_owner() const { return Glib::convert_const_gchar_ptr_to_ustring(gconf_schema_get_owner(const_cast(gobj()))); } Value Schema::get_default_value() const { return Value(gconf_schema_get_default_value(const_cast(gobj()))); } } // namespace Conf } // namespace Gnome