1package VM::EC2::Volume::Status::Action; 2 3=head1 NAME 4 5VM::EC2::Volume::Status::Action - Object describing a scheduled volume maintenance event 6 7=head1 SYNOPSIS 8 9 @status_items = $ec2->describe_volume_status(); 10 for my $i (@status_items) { 11 for my $event ($i->events) { 12 print $i->volume_id,': ', 13 $event->code,' ', 14 $event->type, ' ', 15 $event->description,"\n"; 16 } 17 } 18 19=head1 DESCRIPTION 20 21This objects reflects the actions you may have to take in response to 22a volume event, as described at: 23 24http://docs.amazonwebservices.com/AWSEC2/latest/APIReference/ApiReference-query-DescribeVolumeStatus.html 25 26=head1 METHODS 27 28 code -- The code identifying the action. 29 30 eventType -- The ID of the action. 31 32 description -- A description of the action. 33 34 type -- Alias for eventType 35 36 id -- Alias for eventId 37 38When used in a string context, this object interpolates as a string 39using the action code. 40 41=head1 SEE ALSO 42 43L<VM::EC2> 44L<VM::EC2::Generic> 45L<VM::EC2::Volume> 46L<VM::EC2::Volume::Status> 47L<VM::EC2::Volume::StatusItem> 48L<VM::EC2::Volume::Status::Details> 49L<VM::EC2::Tag> 50 51=head1 AUTHOR 52 53Lincoln Stein E<lt>lincoln.stein@gmail.comE<gt>. 54 55Copyright (c) 2012 Ontario Institute for Cancer Research 56 57This package and its accompanying libraries is free software; you can 58redistribute it and/or modify it under the terms of the GPL (either 59version 1, or at your option, any later version) or the Artistic 60License 2.0. Refer to LICENSE for the full license text. In addition, 61please see DISCLAIMER.txt for disclaimers of warranty. 62 63=cut 64 65use strict; 66use base 'VM::EC2::Generic'; 67 68use strict; 69 70sub valid_fields { 71 my $self = shift; 72 return qw(code eventType eventId description); 73} 74 75sub type {shift->eventType} 76sub id {shift->eventId} 77sub short_name { 78 my $self = shift; 79 return $self->code; 80} 81 821; 83 84