RDF::Flow::Pipeline - Pipelines multiple sources
version 0.178
use RDF::Flow::Pipeline; $src = pipeline( @sources ); # shortcut $src = RDF::Flow::Pipeline->new( @sources ); # explicit $rdf = $src->retrieve( $env ); $rdf == $env->{'rdflow.data'}; # always true # pipeline as conditional: if $s1 has content then union of $s1 and $s2 use RDF::Flow qw(pipeline union previous); pipeline( $s1, union( previous, $s2 ) ); $s1->pipe_to( union( previous, $s2) ); # equivalent
This RDF::Flow::Source wraps other sources as pipeline. Sources are retrieved one after another. The response of each source is saved in the environment variable rdflow.data which is accesible to the next source. The pipeline is aborted without error if rdflow.data has not content, so you can also use a pipleline as conditional branch. To pipe one source after another, you can also use a source's pipe_to method.
rdflow.data
pipe_to
The module RDF::Flow exports functions pipeline and previous on request.
pipeline
previous
RDF::Flow::Cascade, RDF::Flow::Union
Jakob Voß <voss@gbv.de>
This software is copyright (c) 2011 by Jakob Voß.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install RDF::Flow, copy and paste the appropriate command in to your terminal.
cpanm
cpanm RDF::Flow
CPAN shell
perl -MCPAN -e shell install RDF::Flow
For more information on module installation, please visit the detailed CPAN module installation guide.