NAME

Babble - RSS Feed Aggregator and Blog engine

SYNOPSIS

 use Babble;
 use Babble::DataSource::RSS;

 my $babble = Babble->new ();

 $babble->add_params (meta_title => "Example Babble");
 $babble->add_sources (
	Babble::DataSource::RSS->new (
		-id => "Gergely Nagy",
		-location => 'http://bonehunter.rulez.org/~algernon/blog/index.xml',
		-lwp => {
			agent => "Babble/" . $Babble::VERSION . " (Example)"
		}
        )
 );
 $babble->collect_feeds ();

 print $babble->output (-theme => "sidebar");

DESCRIPTION

Babble is a system to collect, process and display RSS feeds. Designed in a straightforward and extensible manner, Babble provides near unlimited flexibility. Even though it provides lots of functionality, the basic usage is pretty simple, and only a few lines.

However, would one want to add new feed item processor functions, that is. also trivial to accomplish.

METHODS

Babble has a handful of methods, all of them will be enumerated here.

    new()

    Creates a new Babble object. Arguments to the new method are listed below, all of them are optional. All arguments passed to new will be stored without parsing, for later use by processors and other extensions.

    -processors

    An array of subroutines that Babble will run for each and every item it processes. See the PROCESSORS section for more information about these matters.

    add_params(%params)

    Add custom paramaters to the Babble object, which might be usable for the output generation routines.

    See the documentation of the relevant output method for details.

    add_sources(@sources)

    Adds multiple sources in one go.

    collect_feeds()

    Retrieve and process the feeds that were added to the Babble. All processor routines will be run by this very method.

    Please note that this must be called before the output method!

    sort()

    Sort all the elements in an aggregation by date, and return the sorted array of items. Leaves the work to Babble::Document::Collection->sort().

    all()

    Return all items in an aggregation as an array.

    output(%params)

    Generate the output. This methods recognises two arguments: type, which determines what output method will be used for the actual output itself, and theme, which overrides this, and uses a theme engine instead. (A theme engine is simply a wrapper around a specific output method, with some paramaters pre-filled.)

    The called module needs to be named Babble::Output::$type or Babble::Theme::$theme, and must be a Babble::Output descendant.

    search()

    Dispatch everything to Babble::Document::Collection->search().

PROCESSORS

Processors are subroutines that take four arguments: An item, a channel, a source, and a Babble object (the caller).

An item is a Babble::Document object, channel is a Babble::Document::Collection object, and source is a Babble::DataSource object.

Preprocessors operate on item in-place, doing whatever they want with it, being it adding new fields, modifying others or anything one might come up with.

A default set of preprocessors, which are always run first (unless special hackery is in the works), are provided in the Babble::Processors module. Since they are automatically used, one does not need to add them explicitly.

AUTHOR

Gergely Nagy, algernon@bonehunter.rulez.org

Bugs should be reported at http://bugs.bonehunter.rulez.org/babble.

SEE ALSO

Babble::DataSource, Babble::Document, Babble::Document::Collection, Babble::Output, Babble::Theme, Babble::Processors

1 POD Error

The following errors were encountered while parsing the POD:

Around line 75:

You can't have =items (as at line 81) unless the first thing after the =over is an =item