blib/lib/VM/EC2/ReservedInstance/Listing/InstanceCount.pm untested

filter: Statementstmt 0.0% 0 / 13 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 4 Podpod 0.0% 0 / 1 totaltotal 0.0% 0 / 18 CC 1 SCAR 6.9
CC
1
Cov
0%
valid_fields
2.0
BEGIN
2.0
BEGIN
2.0
CRAP 2.0
1 package VM::EC2::ReservedInstance::Listing::InstanceCounts;
2  
3 =head1 NAME
4  
5 VM::EC2::ReservedInstance::Listing::InstanceCounts - Object describing an Amazon EC2
6 reserved instance listing instance counts
7  
8 =head1 SYNOPSIS
9  
10 use VM::EC2;
11  
12 $ec2 = VM::EC2->new(...);
13 @listings = $ec2->describe_reserved_instances_listings();
14 for my $l (@listings) {
15 foreach ($l->instanceCounts) {
16 print $_,"\n";
17 }
18 }
19  
20 =head1 DESCRIPTION
21  
22 This object represents an Amazon EC2 reserved instance listing instance count
23  
24 =head1 METHODS
25  
26 These object methods are supported:
27  
28 state -- The state of the listed Reserved Instances
29 Valid values: available | sold | cancelled | pending
30
31 instanceCount -- The number of listed Reserved Instances in the state specified by the state
32  
33 =head1 STRING OVERLOADING
34  
35 When used in a string context, this object will interpolate the
36 reservedInstancesListingId.
37  
38 =head1 SEE ALSO
39  
40 L<VM::EC2>
41 L<VM::EC2::Generic>
42  
43 =head1 AUTHOR
44  
45 Lance Kinley E<lt>lkinley@loyaltymethods.com<gt>.
46  
47 Copyright (c) 2014 Loyalty Methods, Inc.
48  
49 This package and its accompanying libraries is free software; you can
50 redistribute it and/or modify it under the terms of the GPL (either
51 version 1, or at your option, any later version) or the Artistic
52 License 2.0. Refer to LICENSE for the full license text. In addition,
53 please see DISCLAIMER.txt for disclaimers of warranty.
54  
55 =cut
56  
57 use strict;
58 use base 'VM::EC2::Generic';
59  
60 use overload
61 '""' => sub {
62 my $self = shift;
63 return $self->state . ' : ' . $self->instanceCount },
64 fallback => 1;
65  
66 sub valid_fields {
67 my $self = shift;
68 return qw(state instanceCount);
69 }
70  
71 1;