| 1 | package VM::EC2::DB::Subnet; | ||
| 2 | |||
| 3 | =head1 NAME | ||
| 4 | |||
| 5 | VM::EC2::DB::Subnet - An RDS Database Subnet | ||
| 6 | |||
| 7 | =head1 SYNOPSIS | ||
| 8 | |||
| 9 | =head1 DESCRIPTION | ||
| 10 | |||
| 11 | =head1 STRING OVERLOADING | ||
| 12 | |||
| 13 | =head1 SEE ALSO | ||
| 14 | |||
| 15 | L<VM::EC2> | ||
| 16 | L<VM::EC2::Generic> | ||
| 17 | L<VM::EC2::DB::Instance> | ||
| 18 | |||
| 19 | =head1 AUTHOR | ||
| 20 | |||
| 21 | Lance Kinley E<lt>lkinley@loyaltymethods.comE<gt>. | ||
| 22 | |||
| 23 | Copyright (c) 2013 Loyalty Methods, Inc. | ||
| 24 | |||
| 25 | This package and its accompanying libraries is free software; you can | ||
| 26 | redistribute it and/or modify it under the terms of the GPL (either | ||
| 27 | version 1, or at your option, any later version) or the Artistic | ||
| 28 | License 2.0. Refer to LICENSE for the full license text. In addition, | ||
| 29 | please see DISCLAIMER.txt for disclaimers of warranty. | ||
| 30 | |||
| 31 | =cut | ||
| 32 | |||
| 33 | use strict; | ||
| 34 | use base 'VM::EC2::Generic'; | ||
| 35 | |||
| 36 | use overload '""' => sub { shift->SubnetIdentifier }, | ||
| 37 | fallback => 1; | ||
| 38 | |||
| 39 | sub valid_fields { | ||
| 40 | my $self = shift; | ||
| 41 | return qw(SubnetAvailabilityZone SubnetIdentifier SubnetStatus); | ||
| 42 | } | ||
| 43 | |||
| 44 | sub zone { shift->SubnetAvailabilityZone->{Name} } | ||
| 45 | |||
| 46 | sub subnet_id { shift->SubnetIdentifier } | ||
| 47 | |||
| 48 | sub status { shift->SubnetStatus } | ||
| 49 | |||
| 50 | 1; |