File Coverage

blib/lib/OpenSearch/Parameters/Cluster/DelRoutingAwareness.pm
Criterion Covered Total %
statement 15 16 93.7
branch n/a
condition n/a
subroutine 5 6 83.3
pod 0 1 0.0
total 20 23 86.9


line stmt bran cond sub pod time code
1             package OpenSearch::Parameters::Cluster::DelRoutingAwareness;
2 4     4   2490 use strict;
  4         10  
  4         14221  
3 4     4   44 use warnings;
  4         27  
  4         306  
4 4     4   44 use feature qw(state);
  4         8  
  4         591  
5 4     4   27 use Types::Standard qw(Str Bool Int);
  4         8  
  4         35  
6 4     4   8691 use Moo::Role;
  4         10  
  4         48  
7              
8             with 'OpenSearch::Parameters';
9              
10             has 'attribute' => (
11             is => 'rw',
12             isa => Str,
13             );
14              
15             around [qw/attribute/] => sub {
16             my $orig = shift;
17             my $self = shift;
18              
19             if (@_) {
20             $self->$orig(@_);
21             return ($self);
22             }
23             return ( $self->$orig );
24             };
25              
26             sub api_spec {
27 0     0 0   state $s = +{
28             attribute => {
29             encode_func => 'as_is',
30             type => 'path',
31             }
32             };
33             }
34              
35             1;