Amazon/Validate/Type/ItemLookup.pm

filter: Statementstmt 95.6% 22 / 23 Branchbran 75.0% 3 / 4 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 8 / 8 Podpod 0.0% 0 / 4 totaltotal 84.6% 33 / 39 CC 4 SCAR 6.0
CC
4
Cov
93%
validate
3.3
assert
2.0
BEGIN
1.0
CRAP 1.8
« Amazon/Validate/Type/SimilarityLookup.pm ↑ Summary Amazon/Result/Seller/Listing.pm »
1 # -*- perl -*-
2 # !!! DO NOT EDIT !!!
3 # This file was automatically generated.
4 package Net::Amazon::Validate::Type::ItemLookup;
5  
6 7 ▶use 5.006;
Subroutine BEGIN: called CC=1 SCAR=0.0
7 7 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
8 7 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
9  
10 7 ▶use constant RESPONSEGROUP_VALID_VALUES => {
Subroutine BEGIN: called CC=1 SCAR=0.0
11 'Accessories' => 1,
12 'AlternateVersions' => 1,
13 'BrowseNodes' => 1,
14 'Collections' => 1,
15 'EditorialReview' => 1,
16 'Images' => 1,
17 'ItemAttributes' => 1,
18 'ItemIds' => 1,
19 'Large' => 1,
20 'ListmaniaLists' => 1,
21 'Medium' => 1,
22 'MerchantItemAttributes' => 1,
23 'OfferFull' => 1,
24 'OfferListings' => 1,
25 'OfferSummary' => 1,
26 'Offers' => 1,
27 'PromotionDetails' => 1,
28 'PromotionSummary' => 1,
29 'RelatedItems' => 1,
30 'Reviews' => 1,
31 'SalesRank' => 1,
32 'Similarities' => 1,
33 'Small' => 1,
34 'Subjects' => 1,
35 'TaggedGuides' => 1,
36 'TaggedItems' => 1,
37 'TaggedListmaniaLists' => 1,
38 'Tags' => 1,
39 'TagsSummary' => 1,
40 'Tracks' => 1,
41 'VariationImages' => 1,
42 'VariationMatrix' => 1,
43 'VariationMinimum' => 1,
44 'VariationOffers' => 1,
45 'VariationSummary' => 1,
46 'Variations' => 1,
47 7 };
48  
49 15 ▶sub new {
Subroutine new: called CC=1 SCAR=0.0
Pod undocumented
50 15 my ($class , %options) = @_;
51 15 my $self = {
52 %options,
53 };
54 15 bless $self, $class;
55 }
56  
57 15 ▶sub assert {
Subroutine assert: called CC=2 SCAR=6.9
Pod undocumented
58 15 my ($self, $value, $name, $href) = @_;
59 15 ▶ die "Unknown type in Net::Amazon::Request constructor: $value" unless defined $href->{$value};
Branch: 1 branch
BranchTrueFalseTotal
unless defined $href->{$value} 1 14 15
60 }
61  
62 15 ▶sub validate {
Subroutine validate: called CC=3 SCAR=12.0
Pod undocumented
63 15 my ($self, $value, $name, $href) = @_;
64 15 ▶ if ( ref ($value) eq 'ARRAY' ) {
Branch: 1 branch
BranchTrueFalseTotal
if (ref $value eq 'ARRAY') { } 0 15 15
65 0 $self->assert($_, $name, $href) for (@$value);
66 } else {
67 15 $self->assert($value, $name, $href);
68 }
69 }
70  
71 15 ▶sub ResponseGroup {
Subroutine ResponseGroup: called CC=1 SCAR=0.0
Pod undocumented
72 15 my ($self, $value) = @_;
73 15 $self->validate($value, "ResponseGroup", (RESPONSEGROUP_VALID_VALUES));
74 }
75  
76 7 1;
« Amazon/Validate/Type/SimilarityLookup.pm ↑ Summary Amazon/Result/Seller/Listing.pm »