File Coverage

blib/lib/Data/ModeMerge/Mode/CONCAT.pm
Criterion Covered Total %
statement 17 17 100.0
branch n/a
condition 1 2 50.0
subroutine 9 9 100.0
pod 4 5 80.0
total 31 33 93.9


line stmt bran cond sub pod time code
1             package Data::ModeMerge::Mode::CONCAT;
2              
3             our $DATE = '2016-02-25'; # DATE
4             our $VERSION = '0.33'; # VERSION
5              
6 31     31   492 use 5.010;
  31         76  
7 31     31   120 use strict;
  31         42  
  31         574  
8 31     31   105 use warnings;
  31         42  
  31         857  
9 31     31   107 use Mo qw(build default);
  31         38  
  31         133  
10             extends 'Data::ModeMerge::Mode::ADD';
11              
12 698     698 1 1586 sub name { 'CONCAT' }
13              
14 8615     8615 1 13197 sub precedence_level { 2 }
15              
16 330     330 1 1001 sub default_prefix { '.' }
17              
18 330     330 1 1377 sub default_prefix_re { qr/^\./ }
19              
20             sub merge_SCALAR_SCALAR {
21 30     30 0 95 my ($self, $key, $l, $r) = @_;
22 30   50     190 ($key, ($l // "") . $r);
23             }
24              
25             1;
26             # ABSTRACT: Handler for Data::ModeMerge CONCAT merge mode
27              
28             __END__
29              
30             =pod
31              
32             =encoding UTF-8
33              
34             =head1 NAME
35              
36             Data::ModeMerge::Mode::CONCAT - Handler for Data::ModeMerge CONCAT merge mode
37              
38             =head1 VERSION
39              
40             This document describes version 0.33 of Data::ModeMerge::Mode::CONCAT (from Perl distribution Data-ModeMerge), released on 2016-02-25.
41              
42             =head1 SYNOPSIS
43              
44             use Data::ModeMerge;
45              
46             =head1 DESCRIPTION
47              
48             This is the class to handle CONCAT merge mode.
49              
50             =for Pod::Coverage ^merge_.*
51              
52             =head1 HOMEPAGE
53              
54             Please visit the project's homepage at L<https://metacpan.org/release/Data-ModeMerge>.
55              
56             =head1 SOURCE
57              
58             Source repository is at L<https://github.com/perlancar/perl-Data-ModeMerge>.
59              
60             =head1 BUGS
61              
62             Please report any bugs or feature requests on the bugtracker website L<https://rt.cpan.org/Public/Dist/Display.html?Name=Data-ModeMerge>
63              
64             When submitting a bug or request, please include a test-file or a
65             patch to an existing test-file that illustrates the bug or desired
66             feature.
67              
68             =head1 AUTHOR
69              
70             perlancar <perlancar@cpan.org>
71              
72             =head1 COPYRIGHT AND LICENSE
73              
74             This software is copyright (c) 2016 by perlancar@cpan.org.
75              
76             This is free software; you can redistribute it and/or modify it under
77             the same terms as the Perl 5 programming language system itself.
78              
79             =cut