DNSMadeEasy/Domain/Record.pm

filter: Statementstmt 37.0% 10 / 27 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 12.5% 2 / 16 Podpod 92.3% 12 / 13 totaltotal 42.8% 24 / 56 CC 1 SCAR 6.3
CC
1
Cov
37%
_build_obj
2.0
ttl
2.0
gtd_location
2.0
CRAP 1.9
« DNSMadeEasy/Domain.pm ↑ Summary DME.pm »
1 package WWW::DNSMadeEasy::Domain::Record;
2 BEGIN {
3 3 ▶ $WWW::DNSMadeEasy::Domain::Record::AUTHORITY = 'cpan:GETTY';
Subroutine BEGIN: called CC=1 SCAR=0.0
4 }
5 {
6 3 $WWW::DNSMadeEasy::Domain::Record::VERSION = '0.001';
7 }
8 # ABSTRACT: A domain record in the DNSMadeEasy API
9  
10 3 ▶use Moo;
Subroutine BEGIN: called CC=1 SCAR=0.0
11  
12 3 has id => (
13 # isa => 'Int',
14 is => 'ro',
15 required => 1,
16 );
17  
18 3 has domain => (
19 # isa => 'WWW::DNSMadeEasy::Domain',
20 is => 'ro',
21 required => 1,
22 );
23  
24 3 has obj => (
25 # isa => 'HashRef',
26 is => 'ro',
27 builder => '_build_obj',
28 lazy => 1,
29 );
30  
31 sub _build_obj {
32 0 ▶ my ( $self ) = @_;
Subroutine _build_obj: not called CC=1 SCAR=6.9
33 0 return $self->domain->dme->request('GET',$self->path);
34 }
35  
36 0 ▶sub ttl { shift->obj->{ttl} }
Subroutine ttl: not called CC=1 SCAR=6.9
Pod documented
37 0 ▶sub gtd_location { shift->obj->{gtdLocation} }
Subroutine gtd_location: not called CC=1 SCAR=6.9
Pod documented
38 0 ▶sub name { shift->obj->{name} }
Subroutine name: not called CC=1 SCAR=6.9
Pod documented
39 0 ▶sub data { shift->obj->{data} }
Subroutine data: not called CC=1 SCAR=6.9
Pod documented
40 0 ▶sub type { shift->obj->{type} }
Subroutine type: not called CC=1 SCAR=6.9
Pod documented
41 0 ▶sub password { shift->obj->{password} }
Subroutine password: not called CC=1 SCAR=6.9
Pod documented
42 0 ▶sub description { shift->obj->{description} }
Subroutine description: not called CC=1 SCAR=6.9
Pod documented
43 0 ▶sub keywords { shift->obj->{keywords} }
Subroutine keywords: not called CC=1 SCAR=6.9
Pod documented
44 0 ▶sub title { shift->obj->{title} }
Subroutine title: not called CC=1 SCAR=6.9
Pod documented
45 0 ▶sub redirect_type { shift->obj->{redirectType} }
Subroutine redirect_type: not called CC=1 SCAR=6.9
Pod documented
46 0 ▶sub hard_link { shift->obj->{hardLink} }
Subroutine hard_link: not called CC=1 SCAR=6.9
Pod documented
47  
48 sub path {
49 0 ▶ my ( $self ) = @_;
Subroutine path: not called CC=1 SCAR=6.9
Pod undocumented
50 0 $self->domain->path_records.'/'.$self->id;
51 }
52  
53 sub delete {
54 0 ▶ my ( $self ) = @_;
Subroutine delete: not called CC=1 SCAR=6.9
Pod documented
55 0 $self->dme->request('DELETE',$self->path);
56 }
57  
58 3 1;
59  
60  
61 __END__
62 =pod
63  
64 =head1 NAME
65  
66 WWW::DNSMadeEasy::Domain::Record - A domain record in the DNSMadeEasy API
67  
68 =head1 VERSION
69  
70 version 0.001
71  
72 =head1 ATTRIBUTES
73  
74 =head2 id
75  
76 =head2 domain
77  
78 =head2 obj
79  
80 =head1 METHODS
81  
82 =head2 $obj->delete
83  
84 =head2 $obj->ttl
85  
86 =head2 $obj->gtd_location
87  
88 =head2 $obj->name
89  
90 =head2 $obj->data
91  
92 =head2 $obj->type
93  
94 =head2 $obj->password
95  
96 =head2 $obj->description
97  
98 =head2 $obj->keywords
99  
100 =head2 $obj->title
101  
102 =head2 $obj->redirect_type
103  
104 =head2 $obj->hard_link
105  
106 =encoding utf8
107  
108 =head1 ATTRIBUTES
109  
110 =head1 METHODS
111  
112 =head1 SUPPORT
113  
114 IRC
115  
116 Join #duckduckgo on irc.freenode.net and highlight Getty or /msg me.
117  
118 Repository
119  
120 http://github.com/Getty/p5-www-dnsmadeeasy
121 Pull request and additional contributors are welcome
122  
123 Issue Tracker
124  
125 http://github.com/Getty/p5-www-dnsmadeeasy/issues
126  
127 =head1 AUTHOR
128  
129 Torsten Raudssus <torsten@raudssus.de>
130  
131 =head1 COPYRIGHT AND LICENSE
132  
133 This software is copyright (c) 2012 by L<Raudssus Social Software|http://www.raudssus.de/>.
134  
135 This is free software; you can redistribute it and/or modify it under
136 the same terms as the Perl 5 programming language system itself.
137  
138 =cut
139  
« DNSMadeEasy/Domain.pm ↑ Summary DME.pm »