File Coverage

lib/eBay/API/XML/Call/GetCrossPromotions/GetCrossPromotionsRequestType.pm
Criterion Covered Total %
statement 7 9 77.7
branch n/a
condition n/a
subroutine 3 3 100.0
pod n/a
total 10 12 83.3


line stmt bran cond sub pod time code
1             #!/usr/bin/perl
2              
3             package eBay::API::XML::Call::GetCrossPromotions::GetCrossPromotionsRequestType;
4              
5 1     1   3161 use strict;
  1         3  
  1         54  
6 1     1   8 use warnings;
  1         5  
  1         50  
7              
8             ##########################################################################
9             #
10             # Module: ............... eBay/API/XML
11             # File: ................. GetCrossPromotionsRequestType.pm
12             # Generated by: ......... genEBayApiDataTypes.pl
13             # Last Generated: ....... 08/24/2008 16:44
14             # API Release Number: ... 579
15             #
16             ##########################################################################
17              
18             =head1 NAME
19              
20             eBay::API::XML::Call::GetCrossPromotions::GetCrossPromotionsRequestType
21              
22             =head1 DESCRIPTION
23              
24             Retrieves a list of upsell or cross-sell items associated with the specifeid
25             item ID. The seller must be the owner of an eBay Stores storefront to
26             cross-promote items.
27              
28              
29              
30             =head1 SYNOPSIS
31              
32             =cut
33              
34              
35             =head1 INHERITANCE
36              
37             eBay::API::XML::Call::GetCrossPromotions::GetCrossPromotionsRequestType inherits from the L class
38              
39             =cut
40              
41 1     1   63 use eBay::API::XML::RequestDataType;
  0            
  0            
42             our @ISA = ("eBay::API::XML::RequestDataType");
43              
44             use eBay::API::XML::DataType::ItemIDType;
45             use eBay::API::XML::DataType::Enum::PromotionMethodCodeType;
46             use eBay::API::XML::DataType::Enum::TradingRoleCodeType;
47              
48              
49             my @gaProperties = ( [ 'ItemID', 'ns:ItemIDType', ''
50             ,'eBay::API::XML::DataType::ItemIDType', '1' ]
51             , [ 'PromotionMethod', 'ns:PromotionMethodCodeType', ''
52             ,'eBay::API::XML::DataType::Enum::PromotionMethodCodeType', '' ]
53             , [ 'PromotionViewMode', 'ns:TradingRoleCodeType', ''
54             ,'eBay::API::XML::DataType::Enum::TradingRoleCodeType', '' ]
55             );
56             push @gaProperties, @{eBay::API::XML::RequestDataType::getPropertiesList()};
57              
58             my @gaAttributes = (
59             );
60             push @gaAttributes, @{eBay::API::XML::RequestDataType::getAttributesList()};
61              
62             =head1 Subroutines:
63              
64             =cut
65              
66             sub new {
67             my $classname = shift;
68             my %args = @_;
69             my $self = $classname->SUPER::new(%args);
70             return $self;
71             }
72              
73             sub isScalar {
74             return 0;
75             }
76              
77              
78              
79             =head2 setItemID()
80              
81             The unique ID of the referring item. The cross-promoted
82             items will supplement this item.
83              
84             MaxLength: 19 (Note: The eBay database specifies 38. Currently, Item IDs are usually 9 to 12 digits)
85              
86             RequiredInput: Yes
87             # Argument: 'ns:ItemIDType'
88              
89             =cut
90              
91             sub setItemID {
92             my $self = shift;
93             $self->{'ItemID'} = shift
94             }
95              
96             =head2 getItemID()
97              
98             # Returns: 'ns:ItemIDType'
99              
100             =cut
101              
102             sub getItemID {
103             my $self = shift;
104             return $self->_getDataTypeInstance( 'ItemID'
105             ,'eBay::API::XML::DataType::ItemIDType');
106             }
107              
108              
109             =head2 setPromotionMethod()
110              
111             The cross-promotion method you want to use for the
112             returned list, either UpSell or CrossSell.
113              
114             RequiredInput: Yes
115             # Argument: 'ns:PromotionMethodCodeType'
116              
117             =cut
118              
119             sub setPromotionMethod {
120             my $self = shift;
121             $self->{'PromotionMethod'} = shift
122             }
123              
124             =head2 getPromotionMethod()
125              
126             # Returns: 'ns:PromotionMethodCodeType'
127              
128             =cut
129              
130             sub getPromotionMethod {
131             my $self = shift;
132             return $self->{'PromotionMethod'};
133             }
134              
135              
136             =head2 setPromotionViewMode()
137              
138             The role of the person requesting to view the cross-promoted
139             items, either seller or buyer. Default is buyer.
140              
141             RequiredInput: No
142             # Argument: 'ns:TradingRoleCodeType'
143              
144             =cut
145              
146             sub setPromotionViewMode {
147             my $self = shift;
148             $self->{'PromotionViewMode'} = shift
149             }
150              
151             =head2 getPromotionViewMode()
152              
153             # Returns: 'ns:TradingRoleCodeType'
154              
155             =cut
156              
157             sub getPromotionViewMode {
158             my $self = shift;
159             return $self->{'PromotionViewMode'};
160             }
161              
162              
163              
164              
165              
166             ## Attribute and Property lists
167             sub getPropertiesList {
168             my $self = shift;
169             return \@gaProperties;
170             }
171              
172             sub getAttributesList {
173             my $self = shift;
174             return \@gaAttributes;
175             }
176              
177              
178              
179             1;