[gnome-db]a Gda_Report object doubt...



Well, I'm at this moment implementing the Gda_report object at the
client side of the report engine and I have one duobt. I you read the
IDL you can get a Gda_Report from to ways:

1- Adding a new Report to the Report Engine.
2.- Getting a previously created one.


Well, I'm writing the object design and I have add to the gda_report_new
method the CORBA call to "add" a new Report Object to the Report Engine
because the previously created ones are got with
GDA_ReportEngine_queryReports:

<code>

#ifdef HAVE_GOBJECT
	object = GDA_REPORT (g_object_new (GDA_TYPE_REPORT, NULL));
#else
	object = gtk_type_new(gda_report_get_type());
#endif
	object->engine = engine;
	CORBA_exception_init(&ev);
	object->corba_report = GDA_ReportEngine_addReport(engine->corba_engine,
\
			
				  rep_name, description, &ev);
</code>

When I implement the gda_report_free I shouldn't call the
GDA_ReportEngine_removeReport method, because if I do it I can't free
the Report Object that I will not use any more at this session but that
will be at the Report Engine, so I will create a gda_report_remove
method to do it and the _free will be only to free the Object.

My doubt is... Is it correct? Must I move the GDA_ReportEngine_addRepor call to a separate
method (gda_report_add)?


Please, I don't know if I have explain my doubt well, if you don't understand me, please tell
me it.

Bye

-- 
Carlos Perelló Marín
mailto:carlos gnome-db org
mailto:carlos hispalinux es
http://www.gnome-db.org
http://www.Hispalinux.es
Valencia - España





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]