Plagger::Plugin::Aggregator::Null - Aggregator that doesn't do anything


Plagger documentation Contained in the Plagger distribution.

Index


Code Index:

NAME

Top

Plagger::Plugin::Aggregator::Null - Aggregator that doesn't do anything

SYNOPSIS

Top

  - module: Aggregator::Null

DESCRIPTION

Top

This plugin implements Plagger Aggregator but it doesn't do anything useful. It could be only useful when you want to just pass subscribed feed to Publish/Notify plugins, or inside test scripts.

AUTHOR

Top

Tatsuhiko Miyagawa

SEE ALSO

Top

Plagger


Plagger documentation Contained in the Plagger distribution.

package Plagger::Plugin::Aggregator::Null;
use strict;
use base qw( Plagger::Plugin );

sub register {
    my($self, $context) = @_;
    $context->register_hook(
        $self,
        'customfeed.handle'  => \&aggregate,
    );
}

sub aggregate {
    my($self, $context, $args) = @_;
    $context->update->add($args->{feed});
    return 1;
}

1;

__END__