Re: tny-maemo-device



On Mon, 2007-04-16 at 10:33 +0300, Dirk-Jan Binnema nokia com wrote:
> Hi,
> 
> I am looking into the TnyMaemoDevice, which abstracts the network
> connection. Currently, TnyMaemoDevice is implemented in terms
> of LibConic
> (http://maemo.org/platform/docs/api-bora/connectivity/libconic/index.htm
> l),
> which is available for Bora (N800) and the "Hacker OS".
> 
> For older versions, the "Internet Connectivity Library" (LibIC)
> (http://maemo.org/platform/docs/howtos/howto_connectivity_guide.html)
> must be used.
> 
> My proposal is to have two devices for Maemo:
> tny-maemo-conic-device.[ch] and
> tny-maemo-ic-device.[ch]), and decide at configure time which one to
> use. 

Agree. That that'll be a TnyMaemoConicDevice anda  TnyMaemoIcDevice
then. Will you also make an abstract TnyMaemoDevice as base object for
those two?

> The second thing is the API itself; TnyDevice should provide a way
> to connect to specific connections, and it should be possible to figure
> out what connections are available, what connection we are currently
> using,
> etc.
> 
> Some of that might be useful as generic TnyDevice features, and I
> propose
> to add two calls:
> 	tny_device_connect    (TnyDevice*, const gchar *id);
> 	tny_device_disconnect (TnyDevice*, const gchar *id);

Over chat we agreed that for now we will only add those APIs to the
specific objects. I would agree with an abstract "TnyMaemoDevice"
holding the API call though"

tny_maemo_device_connect, tny_maemo_device_disconnect or

tny_maemo_conic_device_connect and tny_maemo_conic_device_disconnect or
tny_maemo_ic_device_connect and tny_maemo_ic_device_disconnect


> By allowing "id" to be NULL (meaning "any"), these calls could actually 
> replace the "tny_device_force_(on|off)_line" calls. Of course this
> assumes that
> an id can be represented as a string in all cases.
> 
> Regarding the querying of what connections are there, it seems
> that this is highly device-specific. Therefore I'd rather implement
> those
> in the subclasses. For example, even between the two maemo-specific
> devices, the API/data types are wildly different, and this will
> be visible in the TnyMaemo(IC|Conic)Device as well.
> 
> If agreed, I can provide the TnyMaemoConicDevice, and a basic version
> of TnyMaemoICDevice.
> 
> Best wishes,
> Dirk.
> _______________________________________________
> tinymail-devel-list mailing list
> tinymail-devel-list gnome org
> http://mail.gnome.org/mailman/listinfo/tinymail-devel-list




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