Twilio/Rest/Lookups/V2.pm

filter: Statementstmt 100% 32 / 32 Branchbran 50.0% 3 / 6 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 9 / 9 Podpod 100% 6 / 6 totaltotal 94.3% 50 / 53 CC 4 SCAR 4.1
CC
4
Cov
92%
bucket
2.0
lookup_overrides
2.0
phone_numbers
2.0
CRAP 1.5
« Twilio/Rest/Routes/V3.pm ↑ Summary Twilio/Rest/Insights/V1.pm »
1 # Generated by tools/generate.pl from Twilio's OpenAPI specs. Do not edit this file.
2 package Twilio::Rest::Lookups::V2;
3  
4 2 ▶use 5.016;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 2 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
6  
7 2 ▶use parent 'Twilio::Version';
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 2 our $VERSION = '2.001';
10  
11 10 ▶sub new {
Subroutine new: called CC=1 SCAR=0.0
Pod documented
12 10 my ($class, $domain) = @_;
13 10 my $self = $class->SUPER::new($domain);
14 10 $self->{version} = 'v2';
15 10 return $self;
16 }
17  
18 # Each of these objects is built on demand, for the reason given in Twilio::Rest::Client.
19 3 ▶sub bucket {
Subroutine bucket: called CC=2 SCAR=7.0
Pod documented
20 3 my ($self, $field, $bucket) = @_;
21 3 require Twilio::Rest::Lookups::V2::Bucket;
22 3 my $list = Twilio::Rest::Lookups::V2::BucketList->new($self, $field);
23 3 ▶ return defined $bucket ? $list->get_context($bucket) : $list;
Branch: 1 branch
BranchTrueFalseTotal
defined $bucket ? : 3 0 3
24 }
25  
26 4 ▶sub lookup_overrides {
Subroutine lookup_overrides: called CC=2 SCAR=7.0
Pod documented
27 4 my ($self, $phone_number, $field) = @_;
28 4 require Twilio::Rest::Lookups::V2::LookupOverride;
29 4 my $list = Twilio::Rest::Lookups::V2::LookupOverrideList->new($self, $phone_number);
30 4 ▶ return defined $field ? $list->get_context($field) : $list;
Branch: 1 branch
BranchTrueFalseTotal
defined $field ? : 4 0 4
31 }
32  
33 1 ▶sub phone_numbers {
Subroutine phone_numbers: called CC=2 SCAR=7.0
Pod documented
34 1 my ($self, $phone_number) = @_;
35 1 require Twilio::Rest::Lookups::V2::PhoneNumber;
36 1 my $list = Twilio::Rest::Lookups::V2::PhoneNumberList->new($self);
37 1 ▶ return defined $phone_number ? $list->get_context($phone_number) : $list;
Branch: 1 branch
BranchTrueFalseTotal
defined $phone_number ? : 1 0 1
38 }
39  
40 1 ▶sub query {
Subroutine query: called CC=1 SCAR=0.0
Pod documented
41 1 my ($self) = @_;
42 1 require Twilio::Rest::Lookups::V2::Query;
43 1 return Twilio::Rest::Lookups::V2::QueryList->new($self);
44 }
45  
46 1 ▶sub rate_limits {
Subroutine rate_limits: called CC=1 SCAR=0.0
Pod documented
47 1 my ($self) = @_;
48 1 require Twilio::Rest::Lookups::V2::RateLimit;
49 1 return Twilio::Rest::Lookups::V2::RateLimitList->new($self);
50 }
51  
52 2 1;
53  
54 __END__
« Twilio/Rest/Routes/V3.pm ↑ Summary Twilio/Rest/Insights/V1.pm »