| 1 | 3 | ▶ | use v5.36; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 2 | |||
| 3 | package Ekorn::Pipeline::Tooling; | ||
| 4 | |||
| 5 | 3 | ▶ | use Exporter qw(import); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 6 | |||
| 7 | # What each module exports, by default or on request, imported here, so | ||
| 8 | # Exporter can export it again. t/23-tooling.t checks that each tag below | ||
| 9 | # holds every name its module exports. | ||
| 10 | 3 | ▶ | use Ekorn::Pipeline::Stop qw(Stop); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 11 | 3 | ▶ | use Ekorn::Pipeline::Gather qw(gather); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 12 | 3 | ▶ | use Ekorn::Pipeline::Stages::Flow qw(:all); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 13 | 3 | ▶ | use Ekorn::Pipeline::Stages::Batch qw(:all); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 14 | 3 | ▶ | use Ekorn::Pipeline::Stages::Taps qw(:all); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 15 | 3 | ▶ | use Ekorn::Pipeline::Context qw(:all); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 16 | 3 | ▶ | use Ekorn::Pipeline::Sources qw(:all); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 17 | 3 | ▶ | use Ekorn::Pipeline::Sinks qw(:all); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 18 | 3 | ▶ | use Ekorn::Pipeline::Factories qw(:all); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 19 | 3 | ▶ | use Ekorn::Pipeline::JSON qw(:all); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 20 | 3 | ▶ | use Ekorn::Pipeline::CSV qw(:all); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 21 | |||
| 22 | 3 | our %EXPORT_TAGS = ( | |
| 23 | core => [qw(Stop gather)], | ||
| 24 | flow => [ | ||
| 25 | qw(take take_first take_last take_single take_if take_while), | ||
| 26 | qw(drop drop_if drop_while), | ||
| 27 | ], | ||
| 28 | batch => [qw(batch collect)], | ||
| 29 | taps => [qw(peek count_into dump_to tee)], | ||
| 30 | context => [qw(result_number result_original)], | ||
| 31 | sources => [qw(from_array from_fh from_file counter)], | ||
| 32 | sinks => [ | ||
| 33 | qw(count_items keep keep_all keep_first keep_last keep_single), | ||
| 34 | qw(to_fh to_file), | ||
| 35 | ], | ||
| 36 | json => [qw(from_json from_jsonl to_json to_jsonl)], | ||
| 37 | csv => [qw(from_csv to_csv)], | ||
| 38 | words => [ | ||
| 39 | qw(pipeline stage gather source generator yield), | ||
| 40 | qw(sink_one sink_many), | ||
| 41 | ], | ||
| 42 | ); | ||
| 43 | 3 | $EXPORT_TAGS{stages} = [map { @{ $EXPORT_TAGS{$_} } } qw(flow batch taps)]; | |
| 44 | |||
| 45 | # Every name once: gather is in both :core and :words. | ||
| 46 | 3 | our @EXPORT_OK = do { | |
| 47 | 3 | my %seen; | |
| 48 | 135 | grep { !$seen{$_}++ } | |
| 49 | 3 | map { @{ $EXPORT_TAGS{$_} } } | |
| 50 | qw(core stages context sources sinks json csv words); | ||
| 51 | }; | ||
| 52 | 3 | $EXPORT_TAGS{all} = [@EXPORT_OK]; | |
| 53 | |||
| 54 | 3 | 1; | |
| 55 | |||
| 56 | __END__ | ||