File Coverage

lib/eBay/API/XML/DataType/CharityType.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::CharityType;
4              
5 1     1   2424 use strict;
  1         2  
  1         36  
6 1     1   5 use warnings;
  1         2  
  1         35  
7              
8             ##########################################################################
9             #
10             # Module: ............... eBay/API/XML
11             # File: ................. CharityType.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::CharityType
21              
22             =head1 DESCRIPTION
23              
24             Identifies a Giving Works listing and benefiting nonprofit charity organization.
25             Currently supported through the US and eBay Motors sites only. The Ad Format and
26             Mature Audiences categories are not supported.
27             Not applicable for US eBay Motors, international, Real Estate, and Tickets.
28              
29              
30              
31             =head1 SYNOPSIS
32              
33             =cut
34              
35              
36             =head1 INHERITANCE
37              
38             eBay::API::XML::DataType::CharityType inherits from the L class
39              
40             =cut
41              
42 1     1   44 use eBay::API::XML::BaseDataType;
  0            
  0            
43             our @ISA = ("eBay::API::XML::BaseDataType");
44              
45             use eBay::API::XML::DataType::Enum::CharityStatusCodeType;
46              
47              
48             my @gaProperties = ( [ 'CharityID', 'xs:string', '', '', '' ]
49             , [ 'CharityListing', 'xs:boolean', '', '', '' ]
50             , [ 'CharityName', 'xs:string', '', '', '' ]
51             , [ 'CharityNumber', 'xs:int', '', '', '' ]
52             , [ 'DonationPercent', 'xs:float', '', '', '' ]
53             , [ 'LogoURL', 'xs:string', '', '', '' ]
54             , [ 'Mission', 'xs:string', '', '', '' ]
55             , [ 'Status', 'ns:CharityStatusCodeType', ''
56             ,'eBay::API::XML::DataType::Enum::CharityStatusCodeType', '' ]
57             );
58             push @gaProperties, @{eBay::API::XML::BaseDataType::getPropertiesList()};
59              
60             my @gaAttributes = (
61             );
62             push @gaAttributes, @{eBay::API::XML::BaseDataType::getAttributesList()};
63              
64             =head1 Subroutines:
65              
66             =cut
67              
68             sub new {
69             my $classname = shift;
70             my %args = @_;
71             my $self = $classname->SUPER::new(%args);
72             return $self;
73             }
74              
75             sub isScalar {
76             return 0;
77             }
78              
79              
80              
81             =head2 setCharityID()
82              
83             A unique identification number assigned by eBay to
84             registered nonprofit charity organizations. Required input
85             when listing Giving Works items.
86              
87             Calls: AddItem
88             GetItemRecommendations
89             RelistItem
90             VerifyAddItem
91             RequiredInput: Conditionally
92              
93             # Argument: 'xs:string'
94              
95             =cut
96              
97             sub setCharityID {
98             my $self = shift;
99             $self->{'CharityID'} = shift
100             }
101              
102             =head2 getCharityID()
103              
104             Calls: GetBidderList
105             Returned: Conditionally
106              
107             Calls: GetItem
108             GetSellerList
109             Returned: Conditionally
110             Details: DetailLevel: ItemReturnDescription, ReturnAll
111              
112             Calls: GetOrderTransactions
113             Returned: Conditionally
114             Details: DetailLevel: none, ItemReturnDescription, ReturnAll
115              
116             # Returns: 'xs:string'
117              
118             =cut
119              
120             sub getCharityID {
121             my $self = shift;
122             return $self->{'CharityID'};
123             }
124              
125              
126             =head2 setCharityListing()
127              
128             If true, indicates that the seller has chosen to use
129             eBay Giving Works to donate a percentage of the item's
130             purchase price to a selected nonprofit organization.
131              
132             # Argument: 'xs:boolean'
133              
134             =cut
135              
136             sub setCharityListing {
137             my $self = shift;
138             $self->{'CharityListing'} = shift
139             }
140              
141             =head2 isCharityListing()
142              
143             Calls: GetSellerList
144             Returned: Conditionally
145             Details: DetailLevel: ItemReturnDescription, ReturnAll
146              
147             Calls: GetItemTransactions
148             GetSellerTransactions
149             Returned: Conditionally
150             Details: DetailLevel: none, ItemReturnDescription, ReturnAll
151              
152             Calls: GetOrderTransactions
153             Returned: Conditionally
154             Details: DetailLevel: none, ItemReturnDescription, ReturnAll
155              
156             # Returns: 'xs:boolean'
157              
158             =cut
159              
160             sub isCharityListing {
161             my $self = shift;
162             return $self->{'CharityListing'};
163             }
164              
165              
166             =head2 setCharityName()
167              
168             The name of the benefiting nonprofit charity organization selected by the
169             charity seller.
170              
171             MaxLength: 150
172              
173             # Argument: 'xs:string'
174              
175             =cut
176              
177             sub setCharityName {
178             my $self = shift;
179             $self->{'CharityName'} = shift
180             }
181              
182             =head2 getCharityName()
183              
184             Calls: GetBidderList
185             Returned: Conditionally
186              
187             Calls: GetOrderTransactions
188             Returned: Conditionally
189             Details: DetailLevel: none, ItemReturnDescription, ReturnAll
190              
191             Calls: GetItem
192             GetSellerList
193             Returned: Conditionally
194             Details: DetailLevel: ItemReturnDescription, ReturnAll
195              
196             # Returns: 'xs:string'
197              
198             =cut
199              
200             sub getCharityName {
201             my $self = shift;
202             return $self->{'CharityName'};
203             }
204              
205              
206             =head2 setCharityNumber()
207              
208             A unique identification number assigned to a nonprofit
209             charity organization by the dedicated provider of
210             eBay Giving Works. Being superseded by CharityID. Max 10
211             digits.
212              
213             Calls: AddItem
214             GetItemRecommendations
215             RelistItem
216             VerifyAddItem
217             RequiredInput: No
218              
219             # Argument: 'xs:int'
220              
221             =cut
222              
223             sub setCharityNumber {
224             my $self = shift;
225             $self->{'CharityNumber'} = shift
226             }
227              
228             =head2 getCharityNumber()
229              
230             Calls: GetBidderList
231             Returned: Conditionally
232              
233             Calls: GetItem
234             GetSellerList
235             Returned: Conditionally
236             Details: DetailLevel: ItemReturnDescription, ReturnAll
237              
238             Calls: GetOrderTransactions
239             Returned: Conditionally
240             Details: DetailLevel: none, ItemReturnDescription, ReturnAll
241              
242             # Returns: 'xs:int'
243              
244             =cut
245              
246             sub getCharityNumber {
247             my $self = shift;
248             return $self->{'CharityNumber'};
249             }
250              
251              
252             =head2 setDonationPercent()
253              
254             The percentage of the purchase price that the
255             seller chooses to donate to the selected nonprofit
256             organization. This percentage is displayed in the Giving
257             Works item listing. Possible values: 10.0 to 100.0.
258             Percentages must increment by 5.0. Minimum donation
259             percentages may be required for Giving Works listings, see
260             http://pages.ebay.com/help/sell/selling-nonprofit.html for
261             details. DonationPercent is required input when listing
262             Giving Works items.
263              
264             Calls: AddItem
265             GetItemRecommendations
266             RelistItem
267             VerifyAddItem
268             RequiredInput: Conditionally
269              
270             # Argument: 'xs:float'
271              
272             =cut
273              
274             sub setDonationPercent {
275             my $self = shift;
276             $self->{'DonationPercent'} = shift
277             }
278              
279             =head2 getDonationPercent()
280              
281             Calls: GetBidderList
282             Returned: Conditionally
283              
284             Calls: GetItem
285             GetSellerList
286             Returned: Conditionally
287             Details: DetailLevel: ItemReturnDescription, ReturnAll
288              
289             Calls: GetOrderTransactions
290             Returned: Conditionally
291             Details: DetailLevel: none, ItemReturnDescription, ReturnAll
292              
293             # Returns: 'xs:float'
294              
295             =cut
296              
297             sub getDonationPercent {
298             my $self = shift;
299             return $self->{'DonationPercent'};
300             }
301              
302              
303             =head2 setLogoURL()
304              
305             The URL of the nonprofit charity organization. This
306             URL is displayed in the Giving Works item listing.
307              
308             # Argument: 'xs:string'
309              
310             =cut
311              
312             sub setLogoURL {
313             my $self = shift;
314             $self->{'LogoURL'} = shift
315             }
316              
317             =head2 getLogoURL()
318              
319             Calls: GetItem
320             GetSellerList
321             Returned: Conditionally
322             Details: DetailLevel: ItemReturnDescription, ReturnAll
323              
324             Calls: GetBidderList
325             Returned: Conditionally
326              
327             # Returns: 'xs:string'
328              
329             =cut
330              
331             sub getLogoURL {
332             my $self = shift;
333             return $self->{'LogoURL'};
334             }
335              
336              
337             =head2 setMission()
338              
339             The stated mission of the nonprofit charity
340             organization. This mission is displayed in the Giving Works
341             item listing.
342              
343             MaxLength: 511
344              
345             # Argument: 'xs:string'
346              
347             =cut
348              
349             sub setMission {
350             my $self = shift;
351             $self->{'Mission'} = shift
352             }
353              
354             =head2 getMission()
355              
356             Calls: GetBidderList
357             Returned: Conditionally
358              
359             Calls: GetItem
360             GetSellerList
361             Returned: Conditionally
362             Details: DetailLevel: ItemReturnDescription, ReturnAll
363              
364             # Returns: 'xs:string'
365              
366             =cut
367              
368             sub getMission {
369             my $self = shift;
370             return $self->{'Mission'};
371             }
372              
373              
374             =head2 setStatus()
375              
376             The status of the nonprofit charity organization.
377              
378             # Argument: 'ns:CharityStatusCodeType'
379              
380             =cut
381              
382             sub setStatus {
383             my $self = shift;
384             $self->{'Status'} = shift
385             }
386              
387             =head2 getStatus()
388              
389             Calls: GetBidderList
390             Returned: Conditionally
391              
392             Calls: GetItem
393             GetSellerList
394             Returned: Conditionally
395             Details: DetailLevel: ItemReturnDescription, ReturnAll
396              
397             # Returns: 'ns:CharityStatusCodeType'
398              
399             =cut
400              
401             sub getStatus {
402             my $self = shift;
403             return $self->{'Status'};
404             }
405              
406              
407              
408              
409              
410             ## Attribute and Property lists
411             sub getPropertiesList {
412             my $self = shift;
413             return \@gaProperties;
414             }
415              
416             sub getAttributesList {
417             my $self = shift;
418             return \@gaAttributes;
419             }
420              
421              
422              
423             1;