blib/lib/VM/EC2/DB/Endpoint.pm untested

filter: Statementstmt 0.0% 0 / 14 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 5 Podpod 0.0% 0 / 2 totaltotal 0.0% 0 / 21 CC 1 SCAR 6.9
CC
1
Cov
0%
valid_fields
2.0
as_string
2.0
BEGIN
2.0
CRAP 2.0
1 package VM::EC2::DB::Endpoint;
2  
3 =head1 NAME
4  
5 VM::EC2::DB::Endpoint - An RDS Database Endpoint
6  
7 =head1 SYNOPSIS
8  
9 use VM::EC2;
10 ($i) = $ec2->describe_db_instances(-db_instance_identifier => 'mydb');
11 print $i->Endpoint,"\n";
12  
13 =head1 DESCRIPTION
14  
15 This object represents the endpoint of a DB Instance.
16  
17 =head1 STRING OVERLOADING
18  
19 In string context, this object returns a string containing the Address
20 and Port of the endpoint in the form 'Address:Port'.
21  
22 =head1 SEE ALSO
23  
24 L<VM::EC2>
25 L<VM::EC2::Generic>
26 L<VM::EC2::DB::Instance>
27  
28 =head1 AUTHOR
29  
30 Lance Kinley E<lt>lkinley@loyaltymethods.comE<gt>.
31  
32 Copyright (c) 2013 Loyalty Methods, Inc.
33  
34 This package and its accompanying libraries is free software; you can
35 redistribute it and/or modify it under the terms of the GPL (either
36 version 1, or at your option, any later version) or the Artistic
37 License 2.0. Refer to LICENSE for the full license text. In addition,
38 please see DISCLAIMER.txt for disclaimers of warranty.
39  
40 =cut
41  
42 use strict;
43 use base 'VM::EC2::Generic';
44  
45 use overload '""' => sub { shift->as_string },
46 fallback => 1;
47  
48 sub valid_fields {
49 my $self = shift;
50 return qw(Address Port);
51 }
52  
53 sub as_string {
54 my $self = shift;
55 return $self->Address . ':' . $self->Port;
56 }
57  
58 1;