Some TnyFolderStoreIface implementations
- From: Philip Van Hoof <spam pvanhoof be>
- To: tinymail-devel-list gnome org
- Subject: Some TnyFolderStoreIface implementations
- Date: Mon, 28 Aug 2006 14:39:10 +0200
Hey hackers,
This is a TODO item
If somebody feels brave, go ahead. Sooner or later I of course will do
this myself. I'm, however, at this moment prioritising myself to other
parts of the code. For example unit tests, samples, demos and
documentation.
http://tinymail.org/trac/tinymail/wiki/HelpImplementTnyFolderStore
The following implementations of the TnyFolderStoreIface interface
aren't yet implemented for TnyStoreAccount and TnyFolder:
tny-store-account.c:
o. tny_store_account_get_folders_async
o. tny_store_account_remove_folder
o. tny_store_account_create_folder
tny-folder.c:
o. tny_folder_get_folders_async
o. tny_folder_remove_folder
o. tny-folder_create_folder
This basically means that only the get_folders of both is implemented.
This task involves:
o. The contract:
- The get_folders_async method should be a non-blocking method that will
(in the GMainLoop) callback to the function that is pointed at with the
callback function pointer.
At this moment (TnyFolderStoreIface *self, gboolean cancelled, gpointer
user_data) are the parameters of that function. It is allowed to change
that to include the TnyListIface that is passed at the get_folders_async
call (in fact, that is what I have in mind). The API (the interface) is
indeed unfinished here.
Once done, adapt the demo-ui to use the async version of get_folders.
- The remove_folder method should remove the folder passed from the
E-mail service provider (it doesn't have to update the TnyListIface's
that contain folders, that's the responsibility of the application
developer to take care of). There should be a check whether "folder" is
a subfolder of "self".
A consequence of a successful removal is that a get_folders on self will
return one less folder than before the removal.
- The create_folder method should create a new folder "folder" as a
subfolder of "self".
A consequence of a successful removal is that a get_folders on self will
return one more folder than before the creation.
o. A unit test per feature (get_folders_async, remove_folder and
create_folder) should test all the contracts!
--
Philip Van Hoof, software developer at x-tend
home: me at pvanhoof dot be
gnome: pvanhoof at gnome dot org
work: vanhoof at x-tend dot be
http://www.pvanhoof.be - http://www.x-tend.be
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]