File Coverage

lib/eBay/API/XML/DataType/ReviewType.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::DataType::ReviewType;
4              
5 1     1   1334 use strict;
  1         2  
  1         37  
6 1     1   6 use warnings;
  1         2  
  1         36  
7              
8             ##########################################################################
9             #
10             # Module: ............... eBay/API/XML
11             # File: ................. ReviewType.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::DataType::ReviewType
21              
22             =head1 DESCRIPTION
23              
24             A product review written by an eBay member.
25              
26              
27              
28             =head1 SYNOPSIS
29              
30             =cut
31              
32              
33             =head1 INHERITANCE
34              
35             eBay::API::XML::DataType::ReviewType inherits from the L class
36              
37             =cut
38              
39 1     1   41 use eBay::API::XML::BaseDataType;
  0            
  0            
40             our @ISA = ("eBay::API::XML::BaseDataType");
41              
42             use eBay::API::XML::DataType::UserIDType;
43              
44              
45             my @gaProperties = ( [ 'CreationTime', 'xs:dateTime', '', '', '' ]
46             , [ 'Rating', 'xs:int', '', '', '' ]
47             , [ 'Text', 'xs:string', '', '', '' ]
48             , [ 'Title', 'xs:string', '', '', '' ]
49             , [ 'URL', 'xs:anyURI', '', '', '' ]
50             , [ 'UserID', 'ns:UserIDType', ''
51             ,'eBay::API::XML::DataType::UserIDType', '1' ]
52             );
53             push @gaProperties, @{eBay::API::XML::BaseDataType::getPropertiesList()};
54              
55             my @gaAttributes = (
56             );
57             push @gaAttributes, @{eBay::API::XML::BaseDataType::getAttributesList()};
58              
59             =head1 Subroutines:
60              
61             =cut
62              
63             sub new {
64             my $classname = shift;
65             my %args = @_;
66             my $self = $classname->SUPER::new(%args);
67             return $self;
68             }
69              
70             sub isScalar {
71             return 0;
72             }
73              
74              
75              
76             =head2 setCreationTime()
77              
78             The time and date when the reviewer posted the review.
79              
80             # Argument: 'xs:dateTime'
81              
82             =cut
83              
84             sub setCreationTime {
85             my $self = shift;
86             $self->{'CreationTime'} = shift
87             }
88              
89             =head2 getCreationTime()
90              
91             Calls: GetProducts
92             Returned: Conditionally
93              
94             # Returns: 'xs:dateTime'
95              
96             =cut
97              
98             sub getCreationTime {
99             my $self = shift;
100             return $self->{'CreationTime'};
101             }
102              
103              
104             =head2 setRating()
105              
106             The eBay member's rating of the product.
107              
108             Max: 5
109             Min: 0
110              
111             # Argument: 'xs:int'
112              
113             =cut
114              
115             sub setRating {
116             my $self = shift;
117             $self->{'Rating'} = shift
118             }
119              
120             =head2 getRating()
121              
122             Calls: GetProducts
123             Returned: Conditionally
124              
125             # Returns: 'xs:int'
126              
127             =cut
128              
129             sub getRating {
130             my $self = shift;
131             return $self->{'Rating'};
132             }
133              
134              
135             =head2 setText()
136              
137             The text of the review. If the review is longer than
138             2000 characters, the text is cut off and it ends with "...".
139             See Review.URL for a link to the full text of the review.
140              
141             SeeLink: URL: #Response.Product.ReviewDetails.Review.URL
142             Title: (GetProducts) Product.ReviewDetails.Review.URL
143             MaxLength: 2000
144              
145             # Argument: 'xs:string'
146              
147             =cut
148              
149             sub setText {
150             my $self = shift;
151             $self->{'Text'} = shift
152             }
153              
154             =head2 getText()
155              
156             Calls: GetProducts
157             Returned: Conditionally
158              
159             # Returns: 'xs:string'
160              
161             =cut
162              
163             sub getText {
164             my $self = shift;
165             return $self->{'Text'};
166             }
167              
168              
169             =head2 setTitle()
170              
171             The title of the review.
172              
173             MaxLength: 55
174              
175             # Argument: 'xs:string'
176              
177             =cut
178              
179             sub setTitle {
180             my $self = shift;
181             $self->{'Title'} = shift
182             }
183              
184             =head2 getTitle()
185              
186             Calls: GetProducts
187             Returned: Conditionally
188              
189             # Returns: 'xs:string'
190              
191             =cut
192              
193             sub getTitle {
194             my $self = shift;
195             return $self->{'Title'};
196             }
197              
198              
199             =head2 setURL()
200              
201             A link to the full review on the eBay Web site.
202             This URL optimized for natural search: "_W0QQ" is like "?"
203             (question mark), "QQ" is like "&" (ampersand),
204             and "Z" is like "=" (equals sign).
205            
206             Note:
207             For a link to all reviews for the product, remove the upvr parameter
208             from this URL. See the eBay Web Services guide for an example.
209            
210              
211             # Argument: 'xs:anyURI'
212              
213             =cut
214              
215             sub setURL {
216             my $self = shift;
217             $self->{'URL'} = shift
218             }
219              
220             =head2 getURL()
221              
222             Calls: GetProducts
223             Returned: Conditionally
224              
225             # Returns: 'xs:anyURI'
226              
227             =cut
228              
229             sub getURL {
230             my $self = shift;
231             return $self->{'URL'};
232             }
233              
234              
235             =head2 setUserID()
236              
237             The reviewer's eBay user ID.
238              
239             # Argument: 'ns:UserIDType'
240              
241             =cut
242              
243             sub setUserID {
244             my $self = shift;
245             $self->{'UserID'} = shift
246             }
247              
248             =head2 getUserID()
249              
250             Calls: GetProducts
251             Returned: Conditionally
252              
253             # Returns: 'ns:UserIDType'
254              
255             =cut
256              
257             sub getUserID {
258             my $self = shift;
259             return $self->_getDataTypeInstance( 'UserID'
260             ,'eBay::API::XML::DataType::UserIDType');
261             }
262              
263              
264              
265              
266              
267             ## Attribute and Property lists
268             sub getPropertiesList {
269             my $self = shift;
270             return \@gaProperties;
271             }
272              
273             sub getAttributesList {
274             my $self = shift;
275             return \@gaAttributes;
276             }
277              
278              
279              
280             1;