Business/CyberSource/RequestPart/Item.pm

filter: Statementstmt 100% 34 / 34 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 7 / 7 Podpod n/a totaltotal 100% 41 / 41 CC 1 SCAR 0.0
CC
1
Cov
100%
BEGIN
1.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
« Business/CyberSource/RequestPart/InvoiceHeader.pm ↑ Summary Business/CyberSource/RequestPart/PurchaseTotals.pm »
1 package Business::CyberSource::RequestPart::Item;
2 3 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
3 3 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 3 ▶use namespace::autoclean;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 3 our $VERSION = '0.010008'; # VERSION
7  
8 3 ▶use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
9 3 extends 'Business::CyberSource::MessagePart';
10 3 with 'MooseX::RemoteHelper::CompositeSerialization';
11  
12 3 ▶use MooseX::Types::Common::Numeric qw( PositiveOrZeroNum PositiveOrZeroInt );
Subroutine BEGIN: called CC=1 SCAR=0.0
13 3 ▶use MooseX::Types::Common::String qw( NonEmptySimpleStr );
Subroutine BEGIN: called CC=1 SCAR=0.0
14  
15 has quantity => (
16 isa => PositiveOrZeroInt,
17 remote_name => 'quantity',
18 is => 'ro',
19 lazy => 1,
20 2 ▶ default => sub { 1 },
Subroutine __ANON__: called CC=1 SCAR=0.0
21 3 );
22  
23 3 has unit_price => (
24 isa => PositiveOrZeroNum,
25 remote_name => 'unitPrice',
26 is => 'ro',
27 required => 1,
28 );
29  
30 3 has product_code => (
31 isa => NonEmptySimpleStr,
32 remote_name => 'productCode',
33 traits => ['SetOnce'],
34 is => 'rw',
35 );
36  
37 3 has product_name => (
38 isa => NonEmptySimpleStr,
39 remote_name => 'productName',
40 traits => ['SetOnce'],
41 is => 'rw',
42 );
43  
44 3 has product_sku => (
45 isa => NonEmptySimpleStr,
46 remote_name => 'productSKU',
47 traits => ['SetOnce'],
48 is => 'rw',
49 );
50  
51 3 has product_risk => (
52 isa => NonEmptySimpleStr,
53 remote_name => 'productRisk',
54 traits => ['SetOnce'],
55 is => 'rw',
56 );
57  
58 3 has tax_amount => (
59 isa => PositiveOrZeroNum,
60 remote_name => 'taxAmount',
61 traits => ['SetOnce'],
62 is => 'rw',
63 );
64  
65 3 has tax_rate => (
66 isa => PositiveOrZeroNum,
67 remote_name => 'taxRate',
68 traits => ['SetOnce'],
69 is => 'rw',
70 );
71  
72 3 has national_tax => (
73 isa => PositiveOrZeroNum,
74 remote_name => 'nationalTax',
75 traits => ['SetOnce'],
76 is => 'rw',
77 );
78  
79 3 has invoice_number => (
80 isa => NonEmptySimpleStr,
81 remote_name => 'invoiceNumber',
82 is => 'ro',
83 required => 0,
84 );
85  
86 3 __PACKAGE__->meta->make_immutable;
87 3 1;
88  
89 # ABSTRACT: Item Helper Class
90  
91 __END__
« Business/CyberSource/RequestPart/InvoiceHeader.pm ↑ Summary Business/CyberSource/RequestPart/PurchaseTotals.pm »