File Coverage

blib/lib/Net/Amazon/EC2/Volume.pm
Criterion Covered Total %
statement 6 6 100.0
branch n/a
condition n/a
subroutine 2 2 100.0
pod n/a
total 8 8 100.0


line stmt bran cond sub pod time code
1             package Net::Amazon::EC2::Volume;
2 2     2   1606 use Moose;
  2         4  
  2         15  
3              
4             =head1 NAME
5              
6             Net::Amazon::EC2::Volume
7              
8             =head1 DESCRIPTION
9              
10             A class representing a volume
11              
12             =head1 ATTRIBUTES
13              
14             =over
15              
16             =item volume_id (required)
17              
18             The ID of the volume.
19              
20             =item size (required)
21              
22             The size, in GiB (1GiB = 2^30 octects)
23              
24             =item snapshot_id (optional)
25              
26             The ID of the snapshot which this volume was created from (if any).
27              
28             =item zone (required)
29              
30             The availability zone the volume was creared in.
31              
32             =item status (required)
33              
34             The volume's status.
35              
36             =item create_time (required)
37              
38             The time the volume was created.
39              
40             =item volume_type (optional)
41              
42             The volume type.
43              
44             =item iops (optional)
45              
46             The number of I/O operations per second (IOPS) that the volume
47             supports (only applies to volumes with a volume_type of io1).
48              
49             =item attachments (optional)
50              
51             An array ref of Net:Amazon::EC2::Attachment objects.
52              
53             =item tag_set (optional)
54              
55             The associated tags (key:value) of the specified volume.
56              
57             =back
58              
59             =cut
60              
61             has 'volume_id' => ( is => 'ro', isa => 'Str', required => 1 );
62             has 'size' => ( is => 'ro', isa => 'Str', required => 1 );
63             has 'snapshot_id' => ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
64             has 'zone' => ( is => 'ro', isa => 'Str', required => 1 );
65             has 'status' => ( is => 'ro', isa => 'Str', required => 1 );
66             has 'create_time' => ( is => 'ro', isa => 'Str', required => 1 );
67             has 'volume_type' => ( is => 'ro', isa => 'Str', default => 'standard');
68             has 'iops' => ( is => 'ro', isa => 'Maybe[Int]');
69             has 'encrypted' => ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
70             has 'attachments' => ( is => 'ro', isa => 'Maybe[ArrayRef[Net::Amazon::EC2::Attachment]]', required => 0 );
71             has 'tag_set' => ( is => 'ro', isa => 'Maybe[ArrayRef[Net::Amazon::EC2::TagSet]]', required => 0 );
72              
73             __PACKAGE__->meta->make_immutable();
74              
75             =head1 AUTHOR
76              
77             Jeff Kim <cpan@chosec.com>
78              
79             =head1 COPYRIGHT
80              
81             Copyright (c) 2006-2010 Jeff Kim. This program is free software; you can redistribute it and/or modify it
82             under the same terms as Perl itself.
83              
84             =cut
85              
86 2     2   13279 no Moose;
  2         4  
  2         11  
87             1;