Object/RtrSet/APNIC.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::RtrSet::APNIC;
2  
3 use strict;
4 use warnings;
5 use base qw/Net::Whois::Object/;
6  
7 # whois -h whois.apnic.net -t rtr-set
8 # % [whois.apnic.net]
9 # % Whois data copyright terms http://www.apnic.net/db/dbcopyright.html
10 #
11 # rtr-set: [mandatory] [single] [primary/lookup key]
12 # descr: [mandatory] [multiple] [ ]
13 # members: [optional] [multiple] [ ]
14 # mp-members: [optional] [multiple] [ ]
15 # mbrs-by-ref: [optional] [multiple] [inverse key]
16 # remarks: [optional] [multiple] [ ]
17 # org: [optional] [multiple] [inverse key]
18 # tech-c: [mandatory] [multiple] [inverse key]
19 # admin-c: [mandatory] [multiple] [inverse key]
20 # notify: [optional] [multiple] [inverse key]
21 # mnt-by: [mandatory] [multiple] [inverse key]
22 # mnt-lower: [optional] [multiple] [inverse key]
23 # changed: [mandatory] [multiple] [ ]
24 # source: [mandatory] [single] [ ]
25 #
26 # % This query was served by the APNIC Whois Service version 1.68.5 (WHOIS4)
27  
28 __PACKAGE__->attributes( 'primary', [ 'rtr_set' ] );
29 __PACKAGE__->attributes( 'mandatory', [ 'rtr_set', 'descr', 'tech_c', 'admin_c', 'mnt_by', 'changed', 'source' ] );
30 __PACKAGE__->attributes( 'optional', [ 'members', 'mp_members', 'mbrs_by_ref', 'remarks', 'org', 'notify', 'mnt_lower' ] );
31 __PACKAGE__->attributes( 'single', [ 'rtr_set', 'source' ] );
32 __PACKAGE__->attributes( 'multiple', [ 'descr', 'members', 'mp_members', 'mbrs_by_ref', 'remarks', 'org', 'tech_c', 'admin_c', 'notify', 'mnt_by', 'mnt_lower', 'changed' ] );
33  
34 =head1 NAME
35  
36 Net::Whois::Object::RtrSet::APNIC - an object representation of the RPSL RtrSet block
37  
38 =head1 DESCRIPTION
39  
40 A rtr-set object defines a set of routers. A set may be described by
41 the "members:" attribute, which is a list of inet-rtr names, IPv4
42 addresses or other rtr-set names. A set may also be populated by means
43 of the "mbrs-by-ref:" attribute, in which case it is represented by
44 inet-rtr objects.
45  
46 =head1 METHODS
47  
48 =head2 B<new( %options )>
49  
50 Constructor for the Net::Whois::Object::RtrSet::APNIC class
51  
52 =cut
53  
54 sub new {
55 my ( $class, @options ) = @_;
56  
57 my $self = bless {}, $class;
58 $self->_init(@options);
59  
60 return $self;
61 }
62  
63 =head2 B<rtr_set( [$rtr_set] )>
64  
65 Accessor to the rtr_set attribute.
66 Accepts an optional rtr_set, always return the current rtr_set.
67  
68 =head2 B<descr( [$descr] )>
69  
70 Accessor to the descr attribute.
71 Accepts an optional descr line to be added to the descr array,
72 always return the current descr array.
73  
74 =head2 B<members( [$member] )>
75  
76 Accessor to the members attribute.
77 Accepts an optional member to be added to the members array,
78 always return the current members array.
79  
80 =head2 B<mbrs_by_ref( [$mbrs_by_ref] )>
81  
82 Accessor to the mbrs_by_ref attribute.
83 Accepts an optional mbrs_by_ref value to be added to the mbrs_by_ref array,
84 always return the current mbrs_by_ref array.
85  
86 =head2 B<remarks( [$remark] )>
87  
88 Accessor to the remarks attribute.
89 Accepts an optional remark to be added to the remarks array,
90 always return the current remarks array.
91  
92 =head2 B<org( [$org] )>
93  
94 Accessor to the org attribute.
95 Accepts an optional org, always return the current org.
96  
97 Points to an existing organisation object representing the entity that
98 holds the resource.
99  
100 The 'ORG-' string followed by 2 to 4 characters, followed by up to 5 digits
101 followed by a source specification. The first digit must not be "0".
102 Source specification starts with "-" followed by source name up to
103 9-character length.
104  
105 =head2 B<tech_c( [$contact] )>
106  
107 Accessor to the tech_c attribute.
108 Accepts an optional contact to be added to the tech_c array,
109 always return the current tech_c array.
110  
111 =head2 B<admin_c( [$contact] )>
112  
113 Accessor to the admin_c attribute.
114 Accepts an optional contact to be added to the admin_c array,
115 always return the current admin_c array.
116  
117 =head2 B<notify( [$notify] )>
118  
119 Accessor to the notify attribute.
120 Accepts an optional notify value to be added to the notify array,
121 always return the current notify array.
122  
123 =head2 B<mnt_by( [$mnt_by])>
124  
125 Accessor to the mnt_by attribute.
126 Accepts an optional mnt_by value to be added to the mnt_by array,
127 always return the current mnt_by array.
128  
129 =head2 B<changed( [$changed] )>
130  
131 Accessor to the changed attribute.
132 Accepts an optional changed value to be added to the changed array,
133 always return the current changed array.
134  
135 =head2 B<source( [$source] )>
136  
137 Accessor to the source attribute.
138 Accepts an optional source, always return the current source.
139  
140 =head2 B<mp_members( [$mp_member] )>
141  
142 Accessor to the mp_members attribute.
143 Accepts an optional mp_member to be added to the mp_members array,
144 always return the current mp_members array.
145  
146 This attribute performs the same function as the members attribute above.
147 The difference is that mp-members allows both IPv4 and IPv6 address families
148 to be specified.
149  
150 Explicitly lists IPv4 or IPv6 'members' of the rtr-set can be:
151  
152 * inet-rtr objects
153 * other rtr-set objects
154 * ipv4 address
155 * ipv6 address
156  
157 =cut
158  
159 1;