Object/AsBlock/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 SCAR 6.9
CC
1
Cov
0%
new
2.0
BEGIN
2.0
BEGIN
2.0
CRAP 2.0
1 package Net::Whois::Object::AsBlock::AFRINIC;
2  
3 use strict;
4 use warnings;
5 use base qw/Net::Whois::Object/;
6  
7 # whois -t as-block -h whois.afrinic.net
8 # % This is the AfriNIC Whois server.
9 #
10 # as-block: [mandatory] [single] [primary/look-up key]
11 # descr: [optional] [multiple] [ ]
12 # remarks: [optional] [multiple] [ ]
13 # org: [optional] [multiple] [inverse key]
14 # admin-c: [mandatory] [multiple] [inverse key]
15 # tech-c: [mandatory] [multiple] [inverse key]
16 # notify: [optional] [multiple] [inverse key]
17 # mnt-by: [mandatory] [multiple] [inverse key]
18 # mnt-lower: [optional] [multiple] [inverse key]
19 # changed: [mandatory] [multiple] [ ]
20 # source: [mandatory] [single] [ ]
21  
22  
23 __PACKAGE__->attributes( 'primary', ['as_block'] );
24 __PACKAGE__->attributes( 'mandatory', [ 'as_block', 'admin_c', 'tech_c', 'mnt_by', 'changed', 'source' ] );
25 __PACKAGE__->attributes( 'optional', [ 'descr', 'remarks', 'org', 'notify', 'mnt_lower' ] );
26 __PACKAGE__->attributes( 'single', [ 'as_block', 'source' ] );
27 __PACKAGE__->attributes( 'multiple', [ 'descr', 'remarks', 'org', 'admin_c', 'tech_c', 'notify', 'mnt_lower', 'mnt_by', 'changed' ] );
28  
29 =head1 NAME
30  
31 Net::Whois::Object::AsBlock::AFRINIC - an object representation of the RPSL AsBlock block
32  
33 =head1 DESCRIPTION
34  
35 An as-block object is needed to delegate a range of AS numbers to a
36 given repository. This object may be used for authorisation of the
37 creation of aut-num objects within the range specified by the
38 "as-block:" attribute.
39  
40 =head1 METHODS
41  
42 =head2 B<new( %options )>
43  
44 Constructor for the Net::Whois::Object::AsBlock::AFRINIC class
45  
46 =cut
47  
48 sub new {
49 my ( $class, @options ) = @_;
50  
51 my $self = bless {}, $class;
52 $self->_init(@options);
53  
54  
55 return $self;
56 }
57  
58 =head2 B<as_block( [$as_block] )>
59  
60 Accessor to the as_block attribute.
61 Accepts an optional as_block, always return the current as_block value.
62  
63 An as_block is a range of AS numbers delegated to a Regional or National Internet Registry
64 (NIR).
65  
66 The AS numbers in the range are subsequently assigned by the registry to
67 members or end-users in the region.
68 Information on individual AS numbers within an as-block object are
69 stored in the appropriate Internet Registry's Whois Database.
70  
71 =head2 B<descr( [$descr] )>
72  
73 Accessor to the descr attribute.
74 Accepts an optional descr, always return the current descr value.
75  
76 Description of the Internet Registry delegated the range of AS numbers shown
77 in the as-block.
78  
79 =head2 B<remarks( [$remarks] )>
80  
81 Accessor to the remarks attribute.
82 Accepts an optional remarks to be added to the remarks array,
83 always return the current remarks array.
84  
85 Information on the registry that maintains details of AS numbers assigned from
86 the as-block.
87  
88 Also includes where to direct a whois client to find further information on
89 the AS numbers.
90  
91 =head2 B<tech_c( [$tech_c] )>
92  
93 Accessor to the tech_c attribute.
94 Accepts an optional tech_c to be added to the tech_c array,
95 always return the current tech_c array.
96  
97 The NIC-handle of a technical contact 'person' or 'role' object. As more than
98 one person often fulfills a role function, there may be more than one tech-c
99 listed.
100  
101 A technical contact (tech-c) must be a person responsible for the
102 day-to-day operation of the network, but does not need to be
103 physically located at the site of the network.
104  
105  
106 =head2 B<admin_c( [$admin_c])>
107  
108 Accessor to the admin_c attribute.
109 Accepts an optional admin_c to be added to the admin_c array,
110 always return the current admin_c array.
111  
112 The NIC-handle of an on-site contact 'person' object. As more than one person
113 often fulfills a role function, there may be more than one admin-c listed.
114  
115 An administrative contact(admin-c) must be someone who is physically
116 located at the site of the network.
117  
118 =head2 B<notify( [$notify] )>
119  
120 Accessor to the notify attribute.
121 Accepts an optional value to be added notify array,
122 always return the current notify array.
123  
124 The email address to which notifications of changes
125 to the object should be sent.
126  
127 =head2 B<mnt_lower( [$mnt_lower] )>
128  
129 Accessor to the mnt_lower attribute.
130 Accepts an optional mnt_lower value to be added to the mnt_lower array,
131 always return the current mnt_lower array.
132  
133 The identifier of a registered 'mntner' object used to authorize the creation
134 of 'aut-num' objects within the range specified by the as-block.
135  
136 If no 'mnt-lower' is specified, the 'mnt-by' attribute is used for
137 authorization.
138  
139 =head2 B<mnt_by( [$mnt_by] )>
140  
141 Accessor to the mnt_by attribute.
142 Accepts an optional mnt_by value to be added to the mnt_by array,
143 always return the current mnt_by array.
144  
145 Lists a registered 'mntner' used to authorize and authenticate changes to this
146 object.
147  
148 When your database details are protected by a 'mntner' object, then
149 only persons with access to the security information of that 'mntner'
150 object will be able to change details.
151  
152 =head2 B<changed( [$changed] )>
153  
154 Accessor to the changed attribute.
155 Accepts an optional changed value to be added to the changed array,
156 always return the current changed array.
157  
158 The email address of who last updated the database object and the date it
159 occurred.
160  
161 Every time a change is made to a database object, this attribute will show
162 the email address of the person who made those changes.
163 Please use the address format specified in RFC 822 - Standard for
164 the Format of ARPA Internet Text Message and provide the date
165 format using one of the following two formats: YYYYMMDD or YYMMDD.
166  
167 =head2 B<source( [$source] )>
168  
169 Accessor to the source attribute.
170 Accepts an optional source, always return the current source.
171  
172 The database where the object is registered.
173  
174 =head2 B<org( [$org] )>
175  
176 Accessor to the org attribute.
177 Accepts an optional org, always return the current org.
178  
179 The organisation entity this object is bound to.
180  
181 =cut
182  
183 1;