Top | ![]() |
![]() |
![]() |
![]() |
GrssFeedsPool * | grss_feeds_pool_new () |
void | grss_feeds_pool_listen () |
GList * | grss_feeds_pool_get_listened () |
int | grss_feeds_pool_get_listened_num () |
void | grss_feeds_pool_switch () |
SoupSession * | grss_feeds_pool_get_session () |
The GrssFeedsPool permits to automatically "listen" for more feeds: it
provides to fetch them on regular intervals (as defined by
grss_feed_channel_get_update_interval()
for each channel), parse them with
GrssFeedParser, and emits signals when feeds are ready.
void grss_feeds_pool_listen (GrssFeedsPool *pool
,GList *feeds
);
To set the list of feeds to be managed by the pool. The previous list, if
any, is invalidated. After invokation to the function, grss_feeds_pool_switch()
must be call to run the auto-fetching (always, also if previous state was
"running").
The list in feeds
can be freed after calling this; linked GrssFeedChannel
are g_object_ref'd here.
GList *
grss_feeds_pool_get_listened (GrssFeedsPool *pool
);
Returns the list of feeds currently managed by the pool
. Please consider
this function has to build the list that returns, and of course this is a
time and resources consuming task: if you only need to know how many feeds
are currently handled, check grss_feeds_pool_get_listened_num()
.
a
list of GrssFeedChannel, to be freed with g_list_free()
when no longer in
use. Do not modify elements found in this list.
[element-type GrssFeedChannel][transfer container]
int
grss_feeds_pool_get_listened_num (GrssFeedsPool *pool
);
Returns number of feeds under the pool
control, as provided by
grss_feeds_pool_listen()
. To get the complete list of those feeds, check
grss_feeds_pool_get_listened()
.
void grss_feeds_pool_switch (GrssFeedsPool *pool
,gboolean run
);
Permits to pause or resume the pool
fetching feeds. If run
is TRUE
, the
pool
starts immediately.
SoupSession *
grss_feeds_pool_get_session (GrssFeedsPool *pool
);
To access the internal SoupSession used by the pool
to fetch items.
“feed-fail”
signalvoid user_function (GrssFeedsPool *pool, GObject *feed, gpointer user_data)
Flags: Run Last
“feed-fetching”
signalvoid user_function (GrssFeedsPool *pool, GObject *feed, gpointer user_data)
Flags: Run Last
“feed-ready”
signalvoid user_function (GrssFeedsPool *pool, GObject *feed, gpointer items, gpointer user_data)
Flags: Run Last