CORBA_any's
- From: Rodrigo Moya <rodrigo gnome-db org>
- To: GNOME Components <gnome-components-list gnome org>
- Cc: Michael Meeks <michael ximian com>
- Subject: CORBA_any's
- Date: 03 Nov 2001 20:52:41 +0100
Hi!
Here are some doubts about CORBA_any's. What I've got is:
typedef CORBA_any GdaValue;
GdaValue *gda_value_new (void);
gchar *gda_value_get_string (GdaValue *value);
void gda_value_set_string (GdaValue *value, const gchar *str);
void gda_value_set_integer (GdaValue *value, gint i);
...
What I'm trying to do is to have a CORBA_any whose CORBA_TypeCode and
value can be changed on the fly. So, in gda_value_set_string I do:
CORBA_Object_release ((CORBA_Object) value->_type, NULL);
value->_type = (CORBA_TypeCode) CORBA_Object_duplicate (
(CORBA_Object) TC_CORBA_string, NULL);
BONOBO_ARG_SET_STRING (value, val);
I do this because I've seen, in bonobo-arg.c (bonobo_arg_new_from), that
the _type member is CORBA_Object_duplicate'd.
But, it seems it's not the correct way, since in another function (after
having called gda_value_set_string), the _type member is just full of
garbage.
How should I do it?
cheers
--
Rodrigo Moya <rodrigo gnome-db org> - <rodrigo ximian com>
http://www.gnome-db.org/ - http://www.ximian.com/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]