Object/Mntner/AFRINIC.pm untested

filter: Statementstmt 0.0% 0 / 23 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 4 Podpod 0.0% 0 / 1 totaltotal 0.0% 0 / 28 CC 1 SCAR 6.9
CC
1
Cov
0%
new
2.0
BEGIN
2.0
BEGIN
2.0
CRAP 2.0
1 package Net::Whois::Object::Mntner::AFRINIC;
2  
3 use strict;
4 use warnings;
5 use base qw/Net::Whois::Object/;
6  
7 # whois -t mntner -h whois.afrinic.net
8 # % This is the AfriNIC Whois server.
9 #
10 # mntner: [mandatory] [single] [primary/look-up key]
11 # descr: [mandatory] [multiple] [ ]
12 # org: [optional] [multiple] [inverse key]
13 # admin-c: [mandatory] [multiple] [inverse key]
14 # tech-c: [optional] [multiple] [inverse key]
15 # upd-to: [mandatory] [multiple] [inverse key]
16 # mnt-nfy: [optional] [multiple] [inverse key]
17 # auth: [mandatory] [multiple] [inverse key]
18 # remarks: [optional] [multiple] [ ]
19 # notify: [optional] [multiple] [inverse key]
20 # abuse-mailbox: [optional] [multiple] [inverse key]
21 # mnt-by: [mandatory] [multiple] [inverse key]
22 # changed: [mandatory] [multiple] [ ]
23 # source: [mandatory] [single] [ ]
24  
25 __PACKAGE__->attributes( 'primary', ['mntner'] );
26 __PACKAGE__->attributes( 'mandatory', [ 'mntner', 'descr', 'admin_c', 'upd_to', 'auth', 'mnt_by', 'changed', 'source' ] );
27 __PACKAGE__->attributes( 'optional', [ 'org', 'tech_c', 'mnt_nfy', 'remarks', 'notify', 'abuse_mailbox' ] );
28 __PACKAGE__->attributes( 'single', [ 'mntner', 'source' ] );
29 __PACKAGE__->attributes( 'multiple', [ 'descr', 'org', 'admin_c', 'tech_c', 'upd_to', 'mnt_nfy', 'auth', 'remarks', 'notify', 'abuse_mailbox', 'mnt_by', 'changed' ] );
30  
31 =head1 NAME
32  
33 Net::Whois::Object::Mntner::AFRINIC - an object representation of the RPSL Mntner block
34  
35 =head1 DESCRIPTION
36  
37 Objects in the RIPE Database may be protected using Mntner (pronounced
38 "maintainer") objects. A Mntner object specifies authentication
39 information required to authorise creation, deletion or modification
40 of the objects protected by the Mntner.
41  
42 Objects are protected by a Mntner, if they contain a reference to the Mntner
43 in the object. This is done by including a mnt-by attribute. Other
44 attributes offer hierarchical protection. The mnt-by attribute is mandatory
45 in all object types. Most users set the mnt-by value in a Mntner to
46 reference itself.
47  
48 =head1 METHODS
49  
50 =head2 B<new( %options )>
51  
52 Constructor for the Net::Whois::Object::Mntner::AFRINIC class
53  
54 =cut
55  
56 sub new {
57 my ( $class, @options ) = @_;
58  
59 my $self = bless {}, $class;
60 $self->_init(@options);
61  
62 return $self;
63 }
64  
65 =head2 B<mntner( [$mntner] )>
66  
67 Accessor to the mntner attribute.
68 Accepts an optional mntner value to be added to the mntner array,
69 always return the current mntner.
70  
71 The unique name of a mntner object. APNIC recommends the following formats:
72  
73 Maintainer for resource registrations:
74  
75 <maint>-<iso3166-code>-<organization>
76  
77 EXAMPLE
78 MAINT-WF-SPARKYNET
79  
80 =head2 B<descr( [$descr] )>
81  
82 Accessor to the descr attribute.
83 Accepts an optional descr line to be added to the descr array,
84 always return the current descr array.
85  
86 A short description of the mntner object and the name of the organization
87 associated with it.
88  
89 =head2 B<org( [$org] )>
90  
91 Accessor to the org attribute.
92 Accepts an optional org value to be added to the org array,
93 always return the current org array.
94  
95 The organisation this object is bound to.
96  
97 =head2 B<admin_c( [$contact] )>
98  
99 Accessor to the admin_c attribute.
100 Accepts an optional contact to be added to the admin_c array,
101 always return the current admin_c array.
102  
103 The NIC-handle of an on-site contact Person object. As more than one
104 person often fulfills a role function, there may be more than one admin_c
105 listed.
106  
107 An administrative contact (admin_c) must be someone who is
108 physically located at the site of the network.
109  
110 =head2 B<tech_c( [$contact] )>
111  
112 Accessor to the tech_c attribute.
113 Accepts an optional contact to be added to the tech_c array,
114 always return the current tech_c array.
115  
116 The NIC-handle of a technical contact Person or Role object. As more than
117 one person often fulfills a role function, there may be more than one tech_c
118 listed.
119  
120 A technical contact (tech_c) must be a person responsible for the
121 day-to-day operation of the network, but does not need to be
122 physically located at the site of the network.
123  
124 =head2 B<upd_to( [$upd_to] )>
125  
126 Accessor to the upd_to attribute.
127 Accepts an optional upd_to value to be added to the upd_to array,
128 always return the current upd_to array.
129  
130 The upd_to attribute specifies the email address to be notified when an
131 attempt to update an object protected by this Mntner is unsuccessful.
132  
133 =head2 B<mnt_nfy( [$mnt_nfy] )>
134  
135 Accessor to the mnt_nfy attribute.
136 Accepts an optional mnt_nfy value to be added to the mnt_nfy array,
137 always return the current mnt_nfy array.
138  
139 The mnt_nfy attribute specifies the email address to be notified when an
140 object protected by this Mntner is successfully updated.
141  
142 =head2 B<auth( [$auth] )>
143  
144 Accessor to the auth attribute.
145 Accepts an optional auth value to be added to the auth array,
146 always return the current auth array.
147  
148 The auth attribute defines an authentication scheme to be used. . Any of
149 the current authentication schemes used by the RIPE Database are allowed.
150  
151 =head2 B<remarks( [$remark] )>
152  
153 Accessor to the remarks attribute.
154 Accepts an optional remark to be addedt to the remarks array,
155 always return the current remarks array.
156  
157 General remarks. May include a URL or email address.
158  
159 =head2 B<notify( [$notify] )>
160  
161 Accessor to the notify attribute.
162 Accepts an optional notify value to be added to the notify array,
163 always return the current notify array.
164  
165 The email address to which notifications of changes to this object should
166 be sent.
167  
168 =head2 B<mnt_by( [$mnt_by] )>
169  
170 Accessor to the mnt_by attribute.
171 Accepts an optional mnt_by value to be added to the mnt_by array,
172 always return the current mnt_by array.
173  
174 Lists a registered Mntner used to authorize and authenticate changes to
175 this object.
176  
177 Most users set the mnt-by value in a Mntner to reference itself.
178  
179 =head2 B<auth_override( [$auth_override] )>
180  
181 Accessor to the auth_override attribute.
182 Accepts an optional auth_override, always return the current auth_override.
183  
184 Routing Policy System Security specification defines an auth_override attribute
185 in the Mntner object template. Together with referral-by attribute, they allow
186 for a Mntner to be modified if it becomes unresponsive.
187 As this is not part of the core functionality of the RIPE Database,
188 it has not been implemented in the current version of the database.
189  
190 =head2 B<referral_by( [$referral_by] )>
191  
192 Accessor to the referral_by attribute.
193 Accepts an optional referral_by, always return the current referral_by.
194  
195 Routing Policy System Security specification defines an auth_override attribute
196 in the Mntner object template. Together with referral-by attribute, they allow
197 for a Mntner to be modified if it becomes unresponsive.
198 As this is not part of the core functionality of the RIPE Database,
199 it has not been implemented in the current version of the database.
200  
201 =head2 B<changed( [$changed] )>
202  
203 Accessor to the changed attribute.
204 Accepts an optional changed value to be added to the changed array,
205 always return the current changed array.
206  
207 The email address of who last updated the database object and the date it
208 occurred.
209  
210 Every time a change is made to a database object, this attribute will show
211 the email address of the person who made those changes.
212 Please use the address format specified in RFC 822 - Standard for
213 the Format of ARPA Internet Text Message and provide the date
214 format using one of the following two formats: YYYYMMDD or YYMMDD.
215  
216 =head2 B<source( [$source] )>
217  
218 Accessor to the source attribute.
219 Accepts an optional source, always return the current source.
220  
221 The name of the database from which the data was obtained.
222  
223 =head2 B<country( [$country] )>
224  
225 Accessor to the country attribute.
226 Accepts an optional value, always return the current 'country'.
227 Two letter ISO 3166 code of the country or economy where the admin-c is based.
228  
229 Please use UPPERCASE letters.
230  
231 =head2 B<abuse_mailbox( [$abuse_mailbox] )>
232  
233 Accessor to the abuse_mailbox attribute.
234 Accepts an optional abuse_mailbox value to be added to the abuse_mailbox array,
235 always return the current abuse_mailbox array.
236  
237 =cut
238  
239 1;