asphalt.feedreader.component¶
-
class
asphalt.feedreader.component.FeedReaderComponent(feeds: typing.Dict[str, typing.Dict[str, typing.Any]] = None, stores: typing.Dict[str, typing.Dict[str, typing.Any]] = None, **feed_defaults)¶ Bases:
asphalt.core.component.ComponentCreates
FeedReaderresources.Parameters:
-
coroutine
asphalt.feedreader.component.create_feed(ctx, reader=None, **reader_args)¶ Create and start a syndication feed.
Note
This function does NOT add the feed to the context as a resource.
Parameters: - ctx (
Context) – a context object (passed to thestart()method) - reader (
Union[str,type,None]) –specifies the feed reader class by one of the following means:
- a subclass of
FeedReader - the entry point name of one
- a
module:varnamereference to one Noneto attempt automatic detection of the feed type
- a subclass of
- reader_args – keyword arguments passed to the feed reader class
Return type: Returns: a feed reader
- ctx (